Toshiba KB-80 Computer Keyboard User Manual


 
- 71 -
WHILE ~ WEND
Function Repeats the statements included between the WHILE statement and the WEND
statement for as long as the given conditions are satisfied.
Format WHILE <expression>
WEND
Term <expression>: The execution is repeated for as long as the <expression> (a numeric
value or character) is satisfied.
Explanation When <expression> is true (other than 0), the steps from WHILE statement to the
WEND statement are executed. After the WEND statement is executed, the
execution returns to the WHILE statement, and then <expression> is evaluated again.
While <expression> is true, the above is repeated. When <expression> is false (0),
the execution skips to the statement after the WEND statement.
If <expression> is false when it is first evaluated, between the WHILE statement and
the WEND statement is not executed and the program moves on to the step following
the WEND statement.
If the WHILE statement and the WEND statement are not paired, a “WHILE Without
WEND” error or “WEND without WHILE” error occurs.