MessageBox

MessageBox ( message [ , [ buttons + icon + default + mode ] [ , boxTitle ] ] )

Elements

message

The message to be displayed in the message box (a string). The length of message is dependent on the operating system.

buttons

Defines the number and type of buttons to be displayed in the message box:

icon

Defines the icons to be displayed in the message box:

default

Defines the default button in the message box. Pressing ENTER has the same effect as clicking the default button:

mode

Defines the message box modality:

boxTitle

The string to appear in the title bar of the message box. boxTitle can be up to 128 characters in length.

Return value

The MessageBox function return value is an integer in the range of 1 to 7, inclusive. This value indicates which button the user pressed in the message box, as shown in the following table.