Purpose |
Display an OpenFile selection dialog to return user choices. | ||||||||||||||||||||||||||
Syntax |
DISPLAY OPENFILE [hParent],
[xpos], [ypos], title$,
folder$, filter$,
_ | ||||||||||||||||||||||||||
hParent |
Handle of the parent window or dialog. If there is no parent, use zero (0) or %HWND_DESKTOP. | ||||||||||||||||||||||||||
xpos |
Horizontal position, in pixels, relative to the parent window. If omitted, PowerBASIC selects the position (offset from the parent, or centered if no parent). | ||||||||||||||||||||||||||
ypos |
Vertical position, in pixels, relative to the parent window. If missing, PowerBASIC selects the position (offset from the parent, or centered if no parent). | ||||||||||||||||||||||||||
title$ |
The title to be displayed in the title bar of the
dialog box. If this parameter is a null
| ||||||||||||||||||||||||||
folder$ |
The name of the initial file directory to be displayed. If this parameter is a null string, the current directory is used. | ||||||||||||||||||||||||||
filter$ |
A string expression containing pairs of null-terminated filter strings. The first string in each pair describes the filter, and the second the filter pattern. For example, if you wish to display BASIC source files, you might use an expression like: "BASIC" + CHR$(0) + "*.BAS" + CHR$(0) A simpler method using the unique characteristics of the CHR$() function in PowerBASIC to achieve the same result: CHR$("BASIC", 0, "*.BAS", 0) Multiple filters can be designated for a single item by separating filter pattern strings with a semicolon: CHR$("BASIC", 0, "*.BAS;*.INC;*.BAK", 0) | ||||||||||||||||||||||||||
start$ |
A string which specifies the starting file name to be used as the initial file selection. This may be disabled by passing a nul, zero-length string (""). | ||||||||||||||||||||||||||
defext$ |
A default extension to be appended to the selected file name if the user does not enter it. This may be disabled by passing a nul, zero-length string (""). | ||||||||||||||||||||||||||
flags |
The style attributes of the OPENFILE Dialog. The following values may be used alone or combined, and are predefined in the PowerBASIC compiler:
| ||||||||||||||||||||||||||
filename$ |
The path and name of the selected file(s). | ||||||||||||||||||||||||||
See also |
DISPLAY BROWSE, DISPLAY COLOR, DISPLAY FONT, DISPLAY SAVEFILE |