Repeat steps UNTIL - < for >() ... [Pro]
Repeat steps UNTIL |
||||||||||||||||||||||||||||||||
This command begins loop that allows macro developer to repeat part of macro (between "for" and "for_end" commands) multiple times. Each "for" command must be followed by "for_end" command. Each loop, a condition defined in "for" command is evaluated and if it is evaluated as "not true" then the "for" loop is ended. It is possible to end the "for" loop also using "for_break" command. |
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
|
||||||||||||||||||||||||||||||||
Example (Macro Steps):
|
||||||||||||||||||||||||||||||||
|
Example (Plain Text):
<#> This macro shows how to use "for" loop.
<#> There are two embedded "for" loops.
<#>
<cmds>
<for>("vX=1","vX < 5","1")
<for>("vY=1","vY < 5","1")
<msg>(-100,-100,"Counters [x,y] = [%vX%,%vY%]
Press F10' to exit this macro.","For Counters",0,0,0)
<me_error_nodisplay> <waitfor>("KEY","PRESS","<F10>",1,0)<me_error_clear><me_error_display>
<if_key>("<F10>","DOWN")
<exitmacro>
<endif>
<for_end>
<for_end>