Can I use findElements() in selenium WebDriver, with multiple Bys.
That is can I use findElements(By.tagName() & By.className()) in Selenium?
You can use the following syntax:
driver.findElement(new ByChained(By.id("foo"),By.xpath("//*[.=’ABCD’]")));
You can see this thread for more details:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With