button_list is an optional list of comma separated strings, which defines the
set of buttons that will be displayed at the bottom of the message box.
A maximum of three buttons can be defined.
If no button_list is given, it defaults to "OK".
The first button in button_list will become the default button (which will be selected if the user hits ENTER), and the last button in the list will become the "cancel button", which is selected if the user hits ESCape or closes the message box. You can make a different button the default button by starting its name with a '+', and you can make a different button the cancel button by starting its name with a '-'. To start a button text with an actual '+' or '-' it has to be escaped.
If a button text contains an '&', the character following the ampersand will become a hotkey, and when the user hits the corresponding key, that button will be selected. To have an actual '&' character in the text it has to be escaped.
The message box can be given an icon by setting the first character of Message to
';' - for an Information
'!' - for a Warning
':' - for an Error
If, however, the Message shall begin with one of these characters, it has to be escaped.
Example
if (dlgMessageBox("!Are you sure?", "&Yes", "&No") == 0) { // let's do it! }
Index | Copyright © 2005 CadSoft Computer GmbH |