EasyManua.ls Logo

GE PACSystems RX7i - Exit Statement

GE PACSystems RX7i
469 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Chapter 8. Structured Text (ST) Programming
382 PACSystems* RX7i, RX3i and RSTi-EP CPU Programmer's Reference Manual GFK-2950C
8.2.10 Exit Statement
The EXIT statement is used to terminate and exit from a loop (FOR, WHILE, REPEAT) before it would
otherwise terminate. Program execution resumes with the statement following the loop terminator
(END_FOR, END_WHILE, END_REPEAT). An EXIT statement is typically used within an IF statement.
Format
EXIT;
Where:
ConditionForExiting An expression that determines whether to terminate early.
Example
The following code fragment shows the operation of the EXIT statement. When the variable number
equals 10, the WHILE loop is exited and execution continues with the statement immediately
following END_WHILE.
while (1) do
a := a + 1;
IF (a = 10) THEN
EXIT;
END_IF;
END_WHILE;

Table of Contents

Other manuals for GE PACSystems RX7i

Related product manuals