Photoshop ships with scripts that do Save As file types. For example "Image Processor.jsx" and "Export Layers To Files.jsx" I would suggest looking at the code in these. I created as "SaveAs.jsx" plug-in script for my own use with code stolen from "Export Layers To Files.jsx".
Great idea, I'm fairly new to all of this stuff, so it's gonna take me a while to try and figure these out. In the meantime if there is a simple solution to getting custom default text into the saveDlg(); function that would be great.
saveDlg(); ??? what is that? Where did you see that? Is that some applescript thing?
I'm not sure where I saw it originally, but it's in the ExtendScript Toolkit library. I'm using it like this -
var dir = Folder('Art'); var pathName = dir.saveDlg('', '.jpg', false);
That opens up a save dialog box at my Art folder and saves the filepath as pathName which I use later to save the document.
File.saveDlg (prompt: string , filter:any): File
Opens the built-in platform-specific file-browsing dialog, in which the user can select an existing file location to which to save information, and creates a new File object to represent the selected file.
Differs from the class method saveDialog() in that it presets the current folder to this File object’s parent folder and the file to this object’s associated file.
If the user clicks OK, returns a File object for the selected file.
If the user cancels, returns null.
prompt: Data Type: string
A string containing the prompt text, if the dialog allows a prompt.
filter (optional): Data Type: any, Default Value: null
In Windows only, a filter that limits the types of files displayed in the dialog.
Very interesting. Well I will keep searching for possibilities through that route and I will start my search for a good Photoshop specific alternative. Thanks for the help, if anyone knows a better way to trigger a save dialog targeted to a specific folder with a default filename written in that would be extremely helpful.