Reply To: Export pages to jpg with custom filenames

#116271
Brian Pifer
Participant

Sorry for the delayed reply.

Add this somewhere in your code:

var myPrompt = prompt(“Name your folder to create on the desktop”);

var f = new Folder(‘~/Desktop/’ + myPrompt);

if (!f.exists)
f.create();

Then you will want to update the myFilePath variable to:

var myFilePath = f.fsName + myPageName + “.jpg”;

Note: I do not have Indesign installed and am a bit rusty. I may be forgetting some slash marks in there, and can’t remember if you will want to use f.fsName or f.fullName. But play with that.

This article was last modified on May 13, 2019

Comments (0)

Loading comments...