Either scenario can be useful, depending on the application and on your requirements.
When you select this check box the Maximum number of iterations field specifies the maximum number of iterations for the loop and the required number of instances for the Extract variable (see Maximum number of iterations).
The Maximum number of iterations field specifies the maximum number of iterations that the loop currently being recorded is allowed to run at runtime. This field is significant only for Extract actions in the current recorded loop for which you have selected the check box Extract data every iteration of the loop.
By default a recorded loop is terminated at runtime on the condition that the default loop variable (a String variable) becomes equal to 'FALSE'. In addition, when the Extract data every iteration of the loop check box is selected for an Extract action inside a loop recording, then a second condition is added to the loop check that terminates the loop at runtime after the number of loop iterations specified in the Maximum number of iterations field is reached. (The two conditions are independent; either condition terminates the loop.)
This same value specified in the Maximum number of iterations field is also the required number of separate instances that the Extract variable must contain, so that the Extract action can store the extracted text into a separate instance of the Extract variable in each iteration of the loop.
The Maximum number of iterations field has no effect on Extract actions in the loop that do not have the Extract data every iteration of the loop check box selected.
Clearing the check box Extract area into variable causes the Extract action to copy all the characters contained in the selected field as a single string into the selected variable. (You select the field from the application screen after the Select Variable window closes.) The Extract action substitutes a blank space for any character in the field that is displayed as a white space in the application screen.
The selected variable must be a simple variable (a String variable).
See Table 1:
| Options for reading the text: | Options for storing the text: | |
|---|---|---|
| Type of variable: | If inside a loop, instances of the variable: | |
| A field in the current application screen. | A simple variable. |
|
| A rectangular area of the current application screen. | A simple variable, with optional character delimiters. | |
| An array variable, with each row of text from the rectangular area stored into an element of the array. | ||
Selecting the check box Extract area into variable causes the Extract action to read all the text contained in the rectangular area that you specify, regardless of field boundaries. The Extract action substitutes a blank space for any character in the rectangular area that is displayed as a white space in the application screen.