RE: Select the values from drop down

How to select all values from drop down  in selenium and how to all values from
dropdown

abirami Default Asked on December 28, 2016 in Selenium WebDriver.
Add Comment
2 Answers

DataTable dt= dc.datacall(“select * from tablename”);
dropdownlist.DataSource = dt;
dropdownlist.DataTextField = “columnname”;
dropdownlist.DataValueField = “id”;
dropdownlist.DataBind();
dropdownlist.Items.Insert(0, “Select “);

Default Answered on January 21, 2017.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.