How can I get the value of text input using Selenium with C #?

Using Selenium for.NET , how can I get the current value from html input?

You can .GetAttribute() get the value attribute, but this is the html attribute, not the current value entered in the text field; an approach like jQuery .val() , not jQuery .attr() .

+7
c # selenium-webdriver
source share
1 answer

Element.Text did not work for me. I used element.GetAttribute("value")

Have a look at this Q&A question. Configuring text box input for text and then extracting it in Specflow and Selenium

+23
source share

All Articles