BREAK Command

BREAK — Transfer control out of a loop structure.

Synopsis

BREAK

Introduction

The BREAK command terminates the current FOR, FOREACH or FOREVER loop and continues processing the command that follows the ENDFOR command.

Arguments

None.

Example

. . .
. . .
FOREVER
    LET V-status = CALL GetNextOrder
    IF V-status = C-OK THEN
        BREAK
    ENDIF
    CALL ProcessOrder
ENDFOR
CALL TotalOrder
. . .
. . .

Related Commands

CONTINUE ENDFOR FOR FOREACH FOREVER