EasyManuals Logo

Omron CX-PROGRAMMER V8.1 User Manual

Omron CX-PROGRAMMER V8.1
231 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
Page #183 background imageLoading...
Page #183 background image
158
Statement Descriptions Section 5-5
Example 2: While X<3000, the value of X is doubled, and the value is substi-
tuted for the array variable DATA[1]. The value of X is then multiplied by 2
again, and the value is substituted for the array variable DATA[2]. This process
is repeated.
n:=1’
WHILE X<3000 DO
X:=X*2;
DATA[n]:=X;
n:=n+1;
END_WHIE;
REPEAT Statement
Summary
This statement is used to repeatedly execute an expression until a specified
condition is true.
Reserved Words
REPEAT, UNTIL, END_REPEAT
Statement Syntax
REPEAT
<expression>;
UNTIL <condition>
END_REPEAT
Processing Flow Chart
Usage
Use the REPEAT statement to repeat processing for as long as a condition is
met after specified processing, when the number of iterations is undetermined
beforehand (depends on whether the condition is met). This statement can be
used to determine whether to repeat processing according to the results of
specified processing execution (post-test loop).
Description
The expression will execute the first time without a condition. Thereafter, the
condition equation will be evaluated. If the condition is false, the expression
will be executed again. If the condition is true, processing will end without exe-
cuting the expression.
Precautions
REPEAT must be used together with END_REPEAT.
Even if the condition equation is true before the expression has been exe-
cuted, the expression will be executed.
Expression
False
Iteration
Tr ue
End
Condition

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron CX-PROGRAMMER V8.1 and is the answer not in the manual?

Omron CX-PROGRAMMER V8.1 Specifications

General IconGeneral
BrandOmron
ModelCX-PROGRAMMER V8.1
CategorySoftware
LanguageEnglish

Related product manuals