Jump to content


Photo

random selection of page's repeater radio buttons


  • Please log in to reply
1 reply to this topic

#1 atraylor

atraylor

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 02 February 2017 - 12:34 PM

Hello,

Is there a way to configure WAPT to randomly select from the available radio buttons on a page?

 

For example, my page has a number of selection options, appearing in the WAPT Name column like this :

 

ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl02$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl03$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl04$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl05$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl06$txtEdit2

etc..

 

To the right of each row is the WAPT Value column.

 

On arecorded session we have '2' next to repeater item 1, as the option was selected.

 

ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl02$txtEdit2                             2

 

How do I configure WAPT to select randomly from one of other 12 repeater text options on the page?

 

Many thanks,

Andrew

 

Attached Files



#2 Sergei Leonov

Sergei Leonov

    Advanced Member

  • Administrators
  • PipPipPip
  • 660 posts

Posted 03 February 2017 - 05:54 AM

As I understood only one random parameter from

ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl02$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl03$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl04$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl05$txtEdit2
ctl00$MainContentPlaceHolder$Repeater1$ctl00$Webdatagrid1$ctl06$txtEdit2

etc..

should have a value.

I suggest you to create variables for all these parameters and use JavaScript operator to randomly initialize only one variable with value, all other should be empty.


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 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users