I know this is going to be a rookie question, but I've spent 2 days on this and I'm desperate.
There are two textboxes on a page I need to populate. They are:
<input type="text" ng-model="searchCtrl.name" placeholder="Name or CRD#" flex="auto" class="ng-pristine ng-untouched ng-valid flex-auto ng-empty" aria-invalid="false">
and
<input type="text" id="firm-input" ng-model="searchCtrl.firm" placeholder="Firm Name or CRD# (optional)" flex="auto" class="ng-pristine ng-untouched ng-valid flex-auto ng-empty" aria-invalid="false">
I can populate the 2nd textbox using:
driver.FindElement(By.Id("acIndividualLocationId")).SendKeys("Sugar Grove, IL");
But as you can see, there is no ID or NAME for the 1st textbox. And I cannot get the CssSelector, TagName, or XPath to work (not sure why).
I can populate the 2nd textbox, THEN move the focus to the 1st textbox by:
driver.FindElement(By.Id("acIndividualLocationId")).SendKeys(Keys.Shift + Keys.Tab);
So here's the rub: how do I populate the 1st textbox now that I have the focus on it???
ENVIRONMENT:
- Windows 10
- Visual Studio 2019
- C#
- Selenium.WebDriver 3.141.0
- Selenium.WebDriver.ChromeDriver 83.0.4103.3900
Thanks in advance…