Welcome to the new DelphiDabbler Code Library Documentation.

This is a new site that's currently running on alpha code. There are going to be bugs. If you discover any, please report them on the site's issues page (GitHub account required). Thanks.

Warning: Many URLs are going to change. Refer to the README file to discover which library project's documentation has been completed.

Execute method

Project: Message Dialogue Components.

Unit: PJMessageDialog.

Class: TPJVCLMsgDlg

Applies to: ~>3.0

function Execute: Integer;

Description

Call Execute to display the dialogue box. Execute returns a value associated with the button that was clicked to close the dialogue box.

Use the ButtonGroup or Buttons properties to determine which buttons are displayed in the dialogue box. The return values are defined in the Controls unit. The return values for buttons that are common both to Windows and the Delphi Controls unit are the same - i.e. the Delphi constants representing theses values map onto those defined by Windows. The possible return values of the various buttons are:

Button clicked Return value Windows Equivalent
Yes mrYes IDYES
No mrNo IDNO
OK mrOK IDOK
Cancel mrCancel IDCANCEL
Abort mrAbort IDABORT
Retry mrRetry IDRETRY
Ignore mrIgnore IDIGNORE
All mrAll N/a
No To All mrNoToAll N/a
Yes To All mrYesToAll N/a
Help N/a (doesn’t close dialogue) N/a
Close mrClose (later Delphis only) N/a