LOCAL prompt statement

Use the LOCAL statement to define variables local to a prompt.

The LOCAL statement must appear at the beginning of the prompt, before any statements that use the local variables.

Once you have defined local variables, you can Select them for use in other statements.

Syntax



Example

LOCAL STRING s1, NUMBER n1;

Procedure

Use the following procedure to define LOCAL statement:

  1. Selecting the LOCAL statement: Click Statements —> Local Variables.

    The system displays the Local Variables window.

  2. Defining the statement: Click Add.

    The system displays the Add Variable window.

  3. If the variable is alphanumeric, click String and type the variable name.

    If the variable is numeric, click Number and type the variable name.

    Note: The first character of the variable name must be a letter.
  4. Click OK.
  5. Repeat Steps 2 through 4 for each required local variable.
  6. Deleting a variable: To delete a variable, select the field value then click Delete.
  7. Adding the statement to the prompt: Click Close.

    The LOCAL statement is added to the prompt, following the INPUT statement.

  8. Selecting local variables: To add a defined local variable to your prompt at the cursor position, click Statements —> Local Variables to Select the variable you want.