Quantcast
Channel: Adobe Community: Message List
Viewing all articles
Browse latest Browse all 97529

Re: save all open document to jpg with new filename with no

$
0
0

Change the way basename is set. Set it to "file_" +  m+1

 

 

#target photoshop;

var startDisplayDialogs = app.displayDialogs

app.displayDialogs = DialogModes.NO

if (app.documents.length > 0) {

   var theFirst = app.activeDocument;

   var theDocs = app.documents;

   jpgOpts = new JPEGSaveOptions( );

   jpgOpts.embedColorProfile = true;

   jpgOpts.formatOptions = FormatOptions.STANDARDBASELINE;

   jpgOpts.matte = MatteType.NONE;

   jpgOpts.quality = 12;

   for (var m = 0; m < theDocs.length; m++) {

     var theDoc = theDocs[m];

     var num = m + 1;

     app.activeDocument = theDoc;

     theDoc.saveAs((new File("~/Desktop/file_" + num)), jpgOpts, false, Extension.LOWERCASE);

   };

   app.activeDocument = theFirst;

};


Viewing all articles
Browse latest Browse all 97529

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>