LABEL (Short Name: LAB)
Top  Previous  Next

In a GOTO or WHENEVER statement, use the LABEL command to identify the command line to which control should be passed.

label

Option

lblname

Specifies a 1 to 18 character name that labels a line to skip to when a GOTO command is executed in a command or procedure file.

MODAL
Allows an EEP command block to launch a Form, Label or Report in a designer. After making appropriate changes, you will have to save the changes and close the designer in order to continue the next command in your EEP.

About the LABEL Command

After a command file is run once, R:BASE stores the labels in memory. When the command file is run again, R:BASE retrieves the location of a label when the GOTO or WHENEVER is run. However, if the GOTO or WHENEVER command is going to be run only once, place the LABEL command below the GOTO or WHENEVER command because it is more efficient for R:BASE to search downward in the command file for the matching label.

Example

In the following example, if the vctrvar variable in the IF...THEN statement is equal to 999, control passes to the command lines following the LABEL command, which defines the endproc label. If vctrvar does not equal 999, the command lines following the ELSE statement are performed.

IF vctrvar = 999 THEN
   GOTO endproc
ELSE
   *( commands to execute )
ENDIF
 
.
.
.
 
LABEL endproc
   *( commands to execute )