FILESAVE Mnemonic - Create File Save Dialog
Syntax
'FILESAVE'(prompt,path,name,ext[,filters])
Description
For BBj-specific information, see FILESAVE Mnemonic - Create File Save Dialog - BBj.
The 'FILESAVE' mnemonic activates the standard File Save dialog.
Parameter |
Description |
prompt |
Text to display in the title bar of the dialog. |
path |
Default directory for the file to be saved in the dialog. |
name |
Default name for the file to be saved in the dialog. Use the empty string ("") to avoid setting a default filename. |
ext |
Default extension (usually 3 characters, do not include the dot) for the file to be saved in the dialog. Use the empty string ("") to avoid setting a default extension. |
filters |
One or more filters in the following format: "text description" + $0a$ + "mask" [+$0a$ + "text description" + $0a$ + "mask" …] The mask specifies an extension, in the format "*.ext" or "*.*"; two or more masks are separated with semicolons. The filter, if included, indicates which files will appear in the list. For example: print 'filesave'("Save Resource File",resource_dir$,"","","Binary Resource Files"+$0a$+"*.brc;*.brf"+$0a$+"ASCII Resource Files"+$0a$+"*.arc"+$0a$+"All Files (*.*)"+$0a$+"*.*")
|
When the dialog is dismissed, a line of text, terminated with $0A$, is injected into the SYSWINDOW stream. The next READ on the channel will receive the text and will be "::BAD::" (error encountered), "::CANCEL::" (user clicked Cancel), or the fully qualified path of the selected file. If the user chooses a name that already exists, overwrite is confirmed. This dialog does not actually cause any files to be saved but returns the name the user has selected.