How do you get all the values from Drop Down list?
Answer Posted / p sureshchowdary
Select dropdown=new Select(d.findElement(By.id("month")));
List<WebElement> list=dropdown.getOptions();
for(WebElement we:list) {
System.out.println(we.getText());
}
| Is This Answer Correct ? | 5 Yes | 0 No |
Post New Answer View All Answers
Describe a framework. List some of the common automation frameworks.
How to highlight element using selenium webdriver?
How to change the url on a webpage using selenium web driver?
How to use frame elements in Selenium on a page?
What differs the configuration of Selenium Selenium 2.0 1.0?
Can we test apis or web services using selenium webdriver?
What programming languages are you able to use in selenium rc?
What are some commonly encountered exceptions in selenium?
Mention what is desired capability? How is it useful in terms of selenium?
what is the difference between driver.get() and driver.navigate.to(“url”)?
What is the selenium's recording language?
What are the different types of wait statements in selenium webdriver?
What is testng assert and list out some common assertions supported by testng?
What is parameterized testing in testng?
How to execute javascript in selenium?