• saveAs ?-w win? ?-file path? ?-encoding enc? ?-ask (0|1)?
Save the specified window with a new name. The -encoding option
specifies the output encoding. The -ask option specifies whether a
save panel should be presented to select the target file's location (the
default value is 0). The -file option has different meanings
depending on the -ask option:
- if -ask is set to 1, the option specifies a default
location to use in the save panel ;
- if -ask is set to 0, the option specifies the path of
the target file so that the contents of the window are saved to this file
directly without presenting any panel.
On success, the command returns the complete path of the saved file,
otherwise it raises an error.