AnsweredAssumed Answered

Simple loop, but endless

Question asked by RedL on Apr 18, 2012
Latest reply on Apr 19, 2012 by disabled_JackRodgers


Simple loop, but endless


I used the below script to show all layout records for new revision export preparation.  I used it almost one year.  It ran very well for my revision data migration preparation.  But, since last week, after I make some design change, the loop becomes endless loop.  Some weird status I found.
1. I have one window only.  But, during the loop it might create multiple windows.  Windows number can up to 100.
2. Supposedly $i should be integer only.  But, I use debug to step script, it will be changed to 100.8 by the GoToLayout step or reset to 1.
Set Variable [$i; Value:1]
 Go to Layout[$i]
 Show All Records
 Set Variable [$i; Value:$i + 1]
 Exit Loop if [$i > 300]
End Loop