Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Can you test the volume that is currnetly selected?

Engaged ,
Aug 09, 2012 Aug 09, 2012

I want to know if the folder I have selected in bridge can be identified as the folder selected?

Like if(00318-000.selected==true){//then do something) something to that nature. I can test if a volume

var myMacHotFolder=(Folder(["/Volumes/Hotfolders/OdystarHotfolder/eDesign"]).exists);

What I want to know is can it be identified as being selected in Bridge? Then I want to get the name of it.

TOPICS
Scripting
1.4K
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Valorous Hero , Aug 09, 2012 Aug 09, 2012

You can get the current folder with :-

alert(app.document.presentationPath);

Translate
Valorous Hero ,
Aug 09, 2012 Aug 09, 2012

You can get the current folder with :-

alert(app.document.presentationPath);

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Aug 09, 2012 Aug 09, 2012

Sweet. Thank you Paul!

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jan 29, 2013 Jan 29, 2013

I am having difficulty with this  (app.document.presentationPath;)  on the PC side. I am running Windows 7. For some reason it is returning an incomplete string.

I am getting 45 characters and I should be getting 67. This works on the Mac side but not PC any Ideas??

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jan 29, 2013 Jan 29, 2013

I am wondering if possibly this is the length of the string? Would that matter?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Valorous Hero ,
Jan 29, 2013 Jan 29, 2013

No the string would have to be in excess of 256 chars.

Have you got any characters in that path that may cause a problem?

You could try this...

alert(decodeURI(app.document.presentationPath));

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jan 30, 2013 Jan 30, 2013

I am afraid that it returned the same result. Everything is there until the end and there is a folder called Pages but it is returning "//string of folders/Pag and it should be Pages. The es is getting chopped off.

?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jan 30, 2013 Jan 30, 2013

OK. I think I understand my problem a little bit more. For some reason not all of the string is showing in the alert. When I write the value to a text file its all there. That doesn't exactly solve my problem but I am much closer now.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Jan 30, 2013 Jan 30, 2013
LATEST

Now that I was able to get the correct string. I have solved my problem.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines