Vcl.Dialogs.TCommonDialog.Execute
Delphi
function Execute: Boolean; overload; virtual;
function Execute(ParentWnd: HWND): Boolean; overload; virtual; abstract;
C++
virtual bool __fastcall Execute()/* overload */;
virtual bool __fastcall Execute(HWND ParentWnd) = 0 /* overload */;
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
function | public | Vcl.Dialogs.pas Vcl.Dialogs.hpp |
Vcl.Dialogs | TCommonDialog |
Description
Displays the dialog box.
TCommonDialog introduces an abstract overload of the Execute method, which descendent classes override in order to open the dialog instance at run time. TCommonDialog also has an overload of the Execute method, overload that is not abstract, which the descendent classes simply inherit. Generally, Execute returns true when the user makes a selection and clicks OK, and returns false when the user closes the dialog without making a selection.
The ParentWnd
parameter is a window handle of type HWND MSDN. If none is provided, the current form handle is used, accessed from Vcl.Forms.TApplication.ActiveFormHandle in the global variable Vcl.Forms.Application.