FindElementByName using partial text
Is this possible? I would like to do something where I can still use the core methods to identify elements such as
FindElementByName FindElementByClassName FindElementByAccesibilityId
But instead of passing in the exact text, I would like to pass in a partial text similar to a contains().
I know that there are ways to do this in XPath, but for whatever reason this is not working. I am certain that my XPath is correct. Is this possible to do with these methods? Has anyone found a way to pass in a partial text? Would be super great if there were methods like
FindElementByPartialName FindElementByPartialClassName FindElementByPartialAccesibilityId
No, you would have to use an XPath. What's the XPath that you're using? The following works fine for me, to find a Tab control containing "foo" in the name:
//Tab[contains(@Name, 'foo')]