This should open the Save As-dialog with the target position being a Folder named »untitled folder« on the Desktop (if it exists).
// 2025, use it at your own risk;
if (app.documents.length > 0) {
try {
var thePath = "~/Desktop/untitled folder";
var theName = activeDocument.name;
var desc6 = new ActionDescriptor();
var desc7 = new ActionDescriptor();
desc6.putObject( stringIDToTypeID( "as" ), stringIDToTypeID( "photoshop35Format" ), desc7 );
desc6.putPath( stringIDToTypeID( "in" ), new File( thePath+"/"+theName ) );
desc6.putBoolean( stringIDToTypeID( "lowerCase" ), true );
desc6.putEnumerated( stringIDToTypeID( "saveStage" ), stringIDToTypeID( "saveStageType" ), stringIDToTypeID( "saveSucceeded" ) );
executeAction( stringIDToTypeID( "save" ), desc6, DialogModes.ALL );
} catch (e) {}
};
... View more