EAGLE Help

dlgFileOpen(), dlgFileSave()


Function
Displays a file dialog.

Syntax
string dlgFileOpen(string Title[, string Start[, string Filter]])
string dlgFileSave(string Title[, string Start[, string Filter]])

Returns
The dlgFileOpen and dlgFileSave functions return the full pathname of the selected file.
If the user has cancelled the dialog, the result will be an empty string.

Description
The dlgFileOpen and dlgFileSave functions display a file dialog from which the user can select a file.

Title will be used as the dialog's title.

If Start is not empty, it will be used as the starting point for the file dialog. Otherwise the current directory will be used.

Only files matching Filter will be displayed. If Filter is empty, all files will be displayed.

Filter can be either a simple wildcard (as in "*.brd"), a list of wildcards (as in "*.bmp *.jpg") or may even contain descriptive text, as in "Bitmap files (*.bmp)". If the "File type" combo box of the file dialog shall contain several entries, they have to be separated by double semicolons, as in "Bitmap files (*.bmp);;Other images (*.jpg *.png)".

See also dlgDirectory

Example

string fileName;
fileName = dlgFileOpen("Select a file", "", "*.brd");

Index Copyright © 2005 CadSoft Computer GmbH