Simple Loop to Introduce a Delay in TI
Posted: Fri Aug 28, 2009 1:17 pm
Just a simple TI snippet to introduce a delay into a TI.
On my hardware mxInternalLoop=1250000 gives a delay of 1 second, so setting mxLoop=30 gives a 30 second delay.
I needed to use this when using ExecuteCommand to copy a large file, see this thread.
Note that I had to move mxLoop out to 60 to get a satisfactory delay that ensured that the server had finished doing whatever it was doing that was stuffing everything up.
On my hardware mxInternalLoop=1250000 gives a delay of 1 second, so setting mxLoop=30 gives a 30 second delay.
I needed to use this when using ExecuteCommand to copy a large file, see this thread.
Note that I had to move mxLoop out to 60 to get a satisfactory delay that ensured that the server had finished doing whatever it was doing that was stuffing everything up.
Code: Select all
#Vary this to give length
mxLoop=30;
ixInternalLoop=1;
ixLoop=1;
mxInternalLoop=1250000;
While(ixLoop<=mxLoop);
ixLoop=ixLoop+1;
ixInternalLoop=1;
While (ixInternalLoop<=mxInternalLoop);
ixInternalLoop= ixInternalLoop+1;
End;
End;