msgbox
Displays a dialog box with the message s.
Syntax
msgbox(s)
R = msgbox(s, c)
R = msgbox(s, c, dummyarg)
Inputs
- s
- Content to display in the dialog. String inputs can have the '\n' newline character, which are displayed on separate lines of the dialog. String elements of cell inputs will be displayed on new lines in the dialog.
- c (optional)
- The caption to be displayed for the dialog.
- dummyarg
- Optional dummy argument for compatibility with legacy scripts.
Outputs
- R
- Type: integer
Examples
R = msgbox('This is a message!!!')
R = 1
Content displayed in the dialog is 'This is a message!!!'
R = msgbox('Message line 1\nMessage line 2', 'My Message')
R = 1
Content displayed in the dialog with the caption 'My Message' is
'Message line 1'
'Message line 1'
R = msgbox({'This', ' is', ' a', ' message!!!'})
R = 1
Content displayed in the dialog is 'This is a message!!!'