Display results as :

Rechercher Advanced Search

Latest topics
» Run automated selenium test scripts from JIRA ondemand
Fri Dec 08, 2017 12:40 pm by azharuddin

» New! Appium Desktop
Sat Nov 25, 2017 3:51 pm by azharuddin

» Selenium WebDriver Integration
Tue Nov 21, 2017 1:06 pm by azharuddin

» how to connect DB in selenium webriver
Fri Oct 06, 2017 4:09 pm by anbarasi

» How find any text in browser screen and click on it?
Thu Oct 05, 2017 2:02 pm by sandeepkommineni

» Selenium Webdriver
Tue Oct 03, 2017 1:35 pm by PiyushBiswas

» GRID setup tutorial.
Wed Sep 27, 2017 4:29 pm by johnyapp

» Drag & Drop Between Windows Using Selenium Driver
Wed Sep 27, 2017 2:10 pm by 26rondel

» Check if window is closed / verify input
Sat Sep 23, 2017 10:21 pm by brainstir


Selecting list of names on web page

View previous topic View next topic Go down

Selecting list of names on web page

Post by seanog1983 on Thu Sep 12, 2013 12:54 pm


I am using Selenium with Firefox to create a Test Case which logs onto a web page and selects a list of Customers. 

Each customer when clicked on displays a list of users. Currently i am selecting each customer and displaying the list of users. The list is quiet long and so the test case for this has alot of same info just been listed line after line. 

Is there a way i can just select the first Customer and then use a loop to display the rest of the customers?


Posts : 1
Join date : 2013-09-12

Back to top Go down

Re: Selecting list of names on web page

Post by ccox on Fri Sep 13, 2013 5:17 am

Yes, you will either first need to download a user-extensions.js file with flow control or install the IDE flow control add in. This will give you the while and endWhile functions. If you specifically need to click on a user's name, create an array and click each user from the array.  Otherwise if you just need to go through all the users in the dropdown, then you can select by the index in which your loop is using.

store |0 | i
while ${i}<numOfUsers
select | id=dropdownName | index=${i}
Do whatever actions/assertions you need to
store | javascript{storedVars.i++}


Posts : 205
Join date : 2012-01-06
Age : 32
Location : Denver, CO

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

Permissions in this forum:
You cannot reply to topics in this forum