For...next statement, Do...loop statement, For...next statement -8 do...loop statement -8 – Sensaphone SCADA 3000 Users manual User Manual
Page 240
22-8
SCADA 3000 User’s Manual
condition-n
Same as condition.
elseifstatements
One or more statements executed if the associated condition-n is True.
elsestatements
One or more statements executed if no previous condition or condition-n expression is
True.
For...Next Statement
Repeats a group of statements a specified number of times.
For counter = start To end [Step step]
[statements]
Next
Arguments
counter
Numeric variable used as a loop counter. The variable can't be an array element or
an element of a user-defined type.
start
Initial value of counter.
end
Final value of counter.
step
Amount counter is changed each time through the loop. If not specified, step defaults
to one.
statements
One or more statements between For and Next that are executed the specified
number of times.
Do...Loop Statement
Repeats a block of statements while a condition is True or until a condition becomes True.
Do [{While | Until} condition]
[statements]
[Exit Do]
[statements]
Loop
Or, you can use this syntax:
Do
[statements]
[Exit Do]
[statements]
Loop [{While | Until} condition]