Next: Custom dialogue boxes
Up: Dialog boxes
Previous: Dialog boxes
Simple dialogue boxes
Some predefined dialogue boxes are available to execute simple tasks such as
reading a string or displaying a text. The type STRINGLIST used in the
following is a string where the characters '|' and newline are used as separators to
create a list of strings. For example, "Ok|Cancel" means the strings "Ok" and
"Cancel".
-
Dialog:Util:ReadInteger(TITLE,MESG,LABEL,DEFAULT)
-
The dialog box created by this function asks the user for an integer value.
- TITLE (input STRING) is the dialog window's title.
- MESG (input STRINGLIST) is a message for the user.
- LABEL (input STRING) is a label associated to the input field.
- DEFAULT (input INT) is the default value of the input field.
- The function returns the integer value given by the user (return INT).
-
Dialog:Util:ReadText(TITLE,MESG,LABEL,DEFAULT )
-
The dialog box created by this function asks the user for a short text (one line).
- TITLE (input STRING) is the dialog window's title.
- MESG (input STRINGLIST) is a message for the user.
- LABEL (input STRING) is a label associated to the input field.
- DEFAULT (input STRING) is the default value of the input field.
- The function returns the short text given by the user (return STRING).
-
Dialog:Util:ReadTextWithChoices(TITLE,MESG,LABEL,DEFAULT,CHOICES)
-
The dialog box created by this function asks the user for a short text (one
line). A list of predefined texts is proposed to the user.
- TITLE (input STRING) is the dialog window's title.
- MESG (input STRINGLIST) is a message for the user.
- LABEL (input STRING) is a label associated to the input field.
- DEFAULT (input STRING) is the default value of the input field.
- CHOICES (input STRINGLIST) is the list of predefined texts.
The function returns the short text given by the user (return STRING).
-
Dialog:Util:AskUser(TITLE,MESG,BUTTONS,TYPE)
-
The dialog box created by this function displays a message and waits to press
an exit button.
- TITLE (input STRING) is the dialog window's title.
- MESG (input STRINGLIST) is a message for the user.
- BUTTONS (input STRINGLIST) is a list of button's labels.
- TYPE (input INT) specify the message type.
0:none 1:information 2:warning 3:working 4:question 5:error
- The function returns the index of the exit button selected by the user (return INT).
-
Dialog:Util:InfoMessage(MESG)
-
The dialog box created by this statement displays a message. No result is
returned
- MESG (input STRING) is the message for the user.
-
Dialog:Util:ErrorMessage(MESG)
-
The dialog box created by this statement displays an error message. No
result is returned.
- MESG (input STRING) is the message for the user.
Next: Custom dialogue boxes
Up: Dialog boxes
Previous: Dialog boxes
Yann Mevel
1999-04-30