Overview | Statement List | Example


输入文本

Synopsis

TEXT/'message',string variable[,ALTACT,'message'],response[,DEFLT]

Description

This statement creates a data entry menu which is displayed in a dialog box and allows the user to interactively assign characters to a string variable.

CAUTION: We do not recommend using the asterisk character (*) in menu prompts or menu options.

TEXT works with the Back, Cancel, and the alternate action option. When one of these options is chosen during program execution while the TEXT statement is pending, the system assigns the following value to the response variable:

Response

Assignment

Back

1

Cancel

2

OK or Return - no text entered

3

Alternate Action

4

OK or Return - text entered

5

You can create an alternate action option by using the minor word ALTACT, followed by a message, as the parameter just before the response variable. The ALTACT message displays as the last option in the dialog box. You can make the message up to forty characters long.

Parameters

Parameter

Description

'message'

A string which represents the title of the menu you want to display. The string can contain up to 40 characters.

string variable

A string variable which is assigned the input characters. If no text is entered a null string variable exists.

ALTACT

Minor word that indicates that an alternate action message is to be displayed as the last option in the dialog box. If the alternate action option is chosen, the response variable equals 4.

'message'

A string or string variable which represents the alternate action message. The string can contain up to forty characters.

response

A variable which is assigned a numerical value based on the user response.

DEFLT

Minor word that indicates that OK can be chosen to accept text which has been previously assigned to the string variable specified. The contents of the string variables is displayed by the TEXT statement. The user may either accept the text or type in new text. If the DEFLT Minor word is not specified, text which may have been assigned to the string variable is not displayed. If OK or Return are used to accept the default text, the value of 3 is assigned to the response variable.


Copyright ©2015 胡君NX二次开发官网(www.UGapi.com) QQ:85585969 All Rights Reserved.