MSG DIALOG
MSG DIALOG displays a customizable message box. You can change the Caption of the buttons with the MSG BUTTON TEXT command, and display an optional checkbox at the bottom of the dialog. The Message parameter specifies the message text, Caption the dialogs title. If you pass an empty string to the Caption parameter, the dialog title will be set according to the Type parameter which should be one of the following values:
1 = Warning- An exclamation-point icon appears in the message box.
2 = Information- An icon consisting of a lowercase letter i in a circle appears in the message box.
3 = Question- A question-mark icon appears in the message box
4 = Stop- A stop-sign icon appears in the message box.
0 = No icon is displayed. The dialog title is the name of the main window.
The Buttons parameter specifies the buttons that will appear in the message box. You can add the values to display a combination of buttons:
1 = Default caption: Yes
2 = Default caption: No
4 = Default caption: OK
8 = Default caption: Cancel
16 = Default caption: Abort
32 = Default caption: Retry
64 = Default caption: Ignore
128 = Default caption: All
256 = Default caption: No to all
512 = Default caption: Yes to all
For example, to show the buttons Yes, No, Abort and All, the Buttons parameter should be 147 (1+2+16+128)
The optional Default Button parameter sets the default button. The value ranges from 1 (default) to the number of buttons displayed. If the optional CheckBox parameter is set to 1, an unticked checkbox will appear at the bottom of the message box; if it is set to 2 the checkbox will be ticked.
ARGUMENTS:
* Message = The message box text
* Caption = The message box title
* Type = The message box type
* Buttons = The message box buttons
optional:
* Default Button = The default button
* Checkbox = The optional checkbox. 0: no checkbox, 1: unticked checkbox, 2: ticked checkbox
RETURNS:
Message box returns an integer value representing the button that the user has pressed:.
1 = Default caption: OK
2 = Default caption: Cancel
3 = Default caption: Abort
4 = Default caption: Retry
5 = Default caption: Ignore
6 = Default caption: Yes
7 = Default caption: No
8 = Default caption: All
9 = Default caption: No to all
10 = Default caption: Yes to all
SYNTAX
Return Integer=MSG DIALOG(Message,Caption,Type,Buttons [,Default Button,Checkbox])
RELATED INFO
View Dialogs Index
View STYX Index
View STYX Main File