Algosim documentation: MessageBox


Displays a GUI message box with text, icon and buttons.



The MessageBox function displays a message box with text, optionally with an icon, and with a custom set of buttons.

(*) Accelerator characters in b are ignored.

The function returns the caption of the chosen button, without any accelerator ampersand. Please note that this function doesn’t return without user intervention.


MessageBox("The value of π is " + π + ".", "information")

Image 1

if(MessageBox("Do you want to exit?", '("&Yes", "&No"), "Yes", "No") = "Yes", exit())

Image 2

MessageBox("There might be a nargle nearby.", "warning", '("Okay, I’ll be careful."))

Image 3

See also