Does File.saveDialog() allow default name?
Posted: September 15th, 2009, 1:04 pm
This is copied straight out of the Javascript Tools CS4.pdf. I'm curious if there is a misprint (which has happened in the past) on the syntax.
Where as File.saveDialog() doesn't seem to...
The preset spot in the brackets leads me to believe that the default name would go there like
Only it doesn't work. I've tried a few combos and nothing. The definitions in the pdf only mention filter not preset. Is this not possible with the latest formatting?
filePutDialog() Allowed for a default name in the save dialog window like so...saveDialog()
File.saveDialog (prompt[, preset])
——————————————————
prompt_____A string containing the prompt text, if the dialog allows a prompt.
filter_______Optional, in Windows only. A filter that limits the types of files displayed in the
dialog. A filter expression, such as "JavaScript:*.jsx;All files:*.*"
_____________Not used in Mac OS.
Opens the built-in platform-specific file-browsing dialog in which a user can select an existing file
location to which to save information, and creates a new File object to represent the selected file
location.
If the user clicks OK, returns a File object for the selected file location. If the user cancels, returns
null.
Code: Select all
filePutDialog(Title, Default Name, Extension Filter);
Code: Select all
File.saveDialog (prompt[, preset])
Code: Select all
File.saveDialog (prompt[, Default Name])