| Applying science to business management |
  
getfile
Format: getfile( filespec, title )
Arguments: (text) filespec Optional file
specification; default = "*.*"
(text) title Optional window title;
default = ""
Returns: (text) Full name of the selected file, or null
if Cancel is pressed
Description: Getfile prompts for a filename using a
dialog box. This box includes an edit line where the user can
type the filename directly, and it also contains a list box from
which the user can choose. Initially, the edit line contains filespec
and the list box contains all files matching this specification.
This primitive is designed to be used in conjunction with others
that require a filename as input.
When Logical Look-Ahead is active, this function is gated to
prevent unnecessary user input in expressions using Logical And/Logical
Or.
Examples: getfile("*.txt")
= prompts for a filename initially listing all TXT files
in the current directory
getfile("*.txt","Text
Files") = same as above but the title Text Files is
put on the dialog box frame
read(getfile) = reads a file
selected by the user
See Also: dialog, getselect, dir
|