How to handle a combobox which when clicked open in new window with list of items(to be clicked) in selenium java ?

+1 vote
Oct 28 in Selenium by Pavithra
• 130 points
168 views

1 answer to this question.

0 votes
@Pavithra, you can try using following commands to handle a combobox:

WebElement ele = driver.findElement(By.id("cmbLocation"));
ComboBox combo = new ComboBox(ele);
combo.expand();
List<WebElement> lis = ele.findElements(By.className("ListBoxItem"));
lis.get(15).click();
answered Oct 29 by Abha
• 27,180 points

Related Questions In Selenium

0 votes
1 answer

How to open a browser window in full screen using Selenium WebDriver with C#

Simply Use this: driver.Manage().Window.Maximize(); READ MORE

answered Jun 7, 2018 in Selenium by Samarpit
• 5,130 points
4,226 views
0 votes
5 answers
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Open new tab instead of a new window in Selenium WebDriver

The current version of Selenium do not ...READ MORE

answered Jun 22, 2018 in Selenium by Meci Matt
• 9,420 points
953 views
0 votes
1 answer
0 votes
2 answers
0 votes
1 answer