Miscellaneous

messagebox

Shows a Windows message box with text, caption, and numeric flags, then returns the integer result code.

Syntax

messagebox(text: string, caption: string, flags: number): integer

Argumente

NameTypBeschreibung
textstringMessage text.
captionstringWindow caption.
flagsnumberNumeric message box flags.

Rückgaben

NameTypBeschreibung
resultintegerInteger result code returned by the message box.

Beschreibung

Shows a Windows message box with text, caption, and numeric flags, then returns the integer result code.

Rufe es mit 3 Parameter(n) auf: text, caption, flags. Die Argumenttabelle erklärt, welche Werte erforderlich sind und welche nur das Verhalten verfeinern.

Es gibt result (integer) zurück. Nutze die Rückgabetabelle, um erfolgreiche Werte von nil-Ergebnissen und behandelbaren Fehlern zu trennen.

Beispiel

Show a Windows message box and read the integer result code returned by the dialog.

local result = messagebox("Real is ready.", "Real", 0)
print(result)