Answered question

I would like to cycle a list of values from a variable extractor

I have configured a variable extractor to get all the occurrences. My goal is to cycle all the occurrences in a loop action in order to change the values on each loop iteration. How can I do this?

When you create a variable extractor, you have an option to extract all the occurrences that will match your configuration.

Let's say your variable extractor name is “MyextractedValues”. This variable contains all your occurrences. You can call each single occurrence using that syntax:

“${MyextractedValues_n} where n is the occurrence number.

 

Example: ${MyextractedValues_2} is the second occurrence of the list of values that you have extracted.

 

Now, each time you create a loop logical action in NeoLoad called by default “loop” (but it can be renamed), a NeoLoad variable is automatically created with a suffix “_counter" so for instance ${loop_counter}.

This variable contains the current loop iteration number. So it will be 1,2, ...n for the first, second...nth iteration number.

By combining your two variables like that ${MyextractedValues_${loop_counter}} you will be able to use a different occurrence on each loop iteration.

 

For more information, see “Logical actions” under “Design” in the NeoLoad documentation.

Did you find this useful ?

No (0)

Yes (0)

0% of users found this answer useful