User Guide
266 Chapter 5: Fireworks JavaScript API
Returns
Nothing.
Description
Restores the specified document to its previously saved version.
fw.runScript()
Availability
Fireworks 3.
Usage
fw.runScript(filename)
Arguments
filename
The name of the script file to execute. If filename is not a file URL (that is, if it
does not begin with
"file:///"), it is assumed to be the name of a file in the Fireworks MX/
Configuration/Commands folder.
Returns
Result of script.
Description
Executes a JavaScript file.
Example
The following command runs a script found in the Align Center to Document.jsf file, which is
located in the Commands folder.
fw.runScript("Align Center to Document.jsf");
fw.saveAll()
Availability
Fireworks 3.
Usage
fw.saveAll()
Arguments
None.
Returns
Nothing.
Description
Saves all open documents, displaying the Save As dialog box for any documents that were not
previously saved.