WAPT Forum: Loop operator - WAPT Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Loop operator help needed with loop operators

#1 User is offline   adoddi@123 

  • Newbie
  • Pip
  • Group: Members
  • Posts: 3
  • Joined: 24-October 11

Posted 27 October 2011 - 01:26 AM

I have a scenario where i have to use the loop operator inorder to execute some requests multiple times. I used the loop operator to do this but the problem is that the loop operaor only allows static values for loop count and my loop count is dynamic. sometimes i want the loop to be executed 5 times and sometimes 6 times depeding on the file size. (I am creating the file dynamically using javascript).

I tried using If else operator inside loop so that the requests are executed only if the condition is met. but the tool does not come out of loop though the condition is not met except that the requests are not executed. I am not sure how to get out of the loop when condition is not met. I also tried using only while loop, but the loop-iteration option is not available in function properties if used while operator with out the loop. (I need this paramter because i am reading the values form a CSV file and i need the tool to read each line for each loop and this can not be done by just using the while loop). Can some body please advice me on how to acheve this? Thanks.
0

#2 User is offline   Sergei Leonov 

  • Advanced Member
  • PipPipPip
  • Group: Administrators
  • Posts: 413
  • Joined: 12-February 08

Posted 27 October 2011 - 08:54 AM

View Postadoddi@123, on 27 October 2011 - 01:26 AM, said:

I have a scenario where i have to use the loop operator inorder to execute some requests multiple times. I used the loop operator to do this but the problem is that the loop operaor only allows static values for loop count and my loop count is dynamic. sometimes i want the loop to be executed 5 times and sometimes 6 times depeding on the file size. (I am creating the file dynamically using javascript).

I tried using If else operator inside loop so that the requests are executed only if the condition is met. but the tool does not come out of loop though the condition is not met except that the requests are not executed. I am not sure how to get out of the loop when condition is not met. I also tried using only while loop, but the loop-iteration option is not available in function properties if used while operator with out the loop. (I need this paramter because i am reading the values form a CSV file and i need the tool to read each line for each loop and this can not be done by just using the while loop). Can some body please advice me on how to acheve this? Thanks.


Ok, we will add an iteration counter to the While operator.
Sergei Leonov
WAPT Project Manager
SoftLogica LLC

Office: +7-383-335-6692
Toll-free: 1-888-364-6797 (for US only)
Time zone GMT +6, EST +11
E-mail: support@loadtestingtool.com
http://www.loadtestingtool.com
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users