4.29 FAQ-388 What can I do if the size of for-loop exceed limitation?

Last Update: 2/3/2015

In LabTalk, the script length limitation of the for loop command is 3072 characters, including white spaces. If the script is too long, you can use define command to first define a macro then call the macro in the loop.

Example:

// Define three macros
define Part1 {ty one;}; 
define Part2 {ty two;}; 
define Part3 {ty three;}; 

// Call macros within for loop
int ii=0; 
for (ii=0;ii<3;ii++) 
{ 
Part1; 
Part2; 
Part3; 
}

Keywords:loop, define macro, character limitation, for, macro