TOpenSaveDialog( unit KOL.pas ) ï TObj ï _TObj

TOpenSaveDialog = object( TObj )

Object to show standard Open/Save dialog. Initially provided for XCL by Carlo Kok.

TOpenSaveDialog properties

property Filename: KOLString;
Filename is separated by #13 when multiselect is true and the first file, is the path of the files selected.

  C:\Projects
  Test1.Dpr
  Test2.Dpr
If only one file is selected, it is provided as (e.g.) C:\Projects\Test1.dpr
For case when OSAllowMultiselect option used, after each call initial value for a Filename containing several files prevents system from opening the dialog. To fix this, assign another initial value to Filename property in your code, when you use multiselect.

property InitialDir: KOLString;
Initial directory path. If not set, current directory (usually directory when program is started) is used.

property Filter: KOLString;
A list of pairs of filter names and filter masks, separated with '¦'. If a mask contains more than one mask, it should be separated with ';'. E.g.:

 'All files|*.*|Text files|*.txt;*.1st;*.diz'

property FilterIndex: Integer;
Index of default filter mask (0 by default, which means "first").

property OpenDialog: Boolean;
True, if "Open" dialog. False, if "Save" dialog. True is default.

property Title: KOLString;
Title for dialog.

property Options: TOpenSaveOptions;
Options.

property DefExtension: KOLString;
Default extention. Set it to desired extension without leading period, e.g. 'txt', but not '.txt'.

property WndOwner: THandle;
Owner window handle. If not assigned, Applet.Handle is used (whenever possible). Assign it, if your application has stay-on-top forms, and a separate Applet object is used.

property OpenReadOnly: Boolean;    Ñ   
TRUE after Execute, if Read Only check box was checked by the user. Options are not affected anyway.

Properties, inherited from TObj

TOpenSaveDialog methods

destructor Destroy; virtual;
destructor

Function Execute: Boolean;
Call it after creating to perform selecting of file by user.

Methods, inherited from TObj

TOpenSaveDialog events

Events, inherited from TObj

TOpenSaveDialog fields

Fields, inherited from TObj


Index ]

This help is generated 14-Jun-2010 by KOL Help generator, (C) 2000-2001 by Vladimir Kladov
Modified (C) 2003 by Alexander Bartov