Overview | Statement List | Example 1 | Example 2
JUMP/label:+,[expression]
Conditional branching is the computed or conditional JUMP statement that causes the program to branch to one of several locations based on the integer portion of a supporting expression or variable. The integer may be set in many ways, either by a numerical expression (RESP=A+B) or by a previous GRIP statement such as PARAM, CHOOSE, TEXT, etc.. If the number being considered is not an integer (4.2516), the integer portion of the expression or variable, which is also referred to as the index, is obtained by truncating without rounding in either direction (4.2516 would be evaluated as 4). The resulting integer causes the program to branch to the label specified by that location in the label list which may consist of up to 43 labels. If a label does not exist in the indicated location (a field between two commas L1:,L2:,,L4:) the program continues with the next statement in the program. If the resulting integer is a zero the JUMP statement is ignored and the program continues with the following statement.
Parameter |
Description |
label: |
A unique label name which the program branches to. A label must end with a colon (:). A label may contain up to six alpha-numeric characters (excluding the colon A12345:), however the first character must be alpha. |
expression |
An expression which results in a numeric value. The numeric value may be set by the expression or by a previous Grip statement. |