0
votes
1answer
65 views

In WebDriver I need to locate a text that's sibling to a tag

I am using WebDriver and I need to use XPath to get the text that appears after the <br></br> which is "59Min" from the below HTML. <div> 2Hrs, 56Min <br></br> 59Min ...
0
votes
1answer
211 views

How to click on Canvas element?

How do I click on a Canvas element by using Selenium Web Driver and Java? I have searched Google but didn't find what I needed. A marker/pin is on the Google map and I have to click on the ...
0
votes
3answers
106 views

how to use xpath for the following case

.//*[@id='colDiv_Apr282014']/div[5]/div[1] .//*[@id='colDiv_Apr282014']/div[9]/div[1] .//*[@id='colDiv_Apr282014']/div[11]/div[1] In the xpath above, you can see the value inside the first div-is ...
0
votes
2answers
197 views

XPath not recognised in page object model in WebDriver [closed]

xpath not recognised in page object model in webdriver. @FindBy(xpath = "//td[contains (text(),'xxx')]") public WebElement topMenu; topMenu.click(); Error: Unable to locate element: ...
2
votes
1answer
1k views

How to indicate an `&nbsp;` in xpath?

Say we have the following HTML code. What I want is to locate to the label element whose text is 'AgendaShowCapacity (1 remaining)' with XPath. <div id="pageContent"> <fieldset> ...
1
vote
2answers
4k views

"Element is no longer attached to the DOM” StaleElementReferenceException when selecting HTML table row

I am using Selenium 2/WebDriver for automation. I have a table and am trying to select a row in it. When the test runs, I can see the row become highlighted as if it is clicked, but then immediately I ...
7
votes
2answers
15k views

WebDriver: find elements by text

I know that WebDriver can locate links through their text, using find_element_by_link_text or find_element_by_partial_link_text. Is it possible to locate any element (such as li, div, span, ...) by ...
3
votes
3answers
9k views

Locating element by link text (anchor tag innerHTML) or xpath fails in Selenium 2.0 Webdriver

I'm using Selenium 2.0 web driver. My script keeps failing whenever I try locating something in my page. It throws an exception whether I locate the element by LinkText or by XPath. ...
3
votes
2answers
1k views

Need help to frame locator for webdriver script

I have a button reach_analysis_button with id="x-auto-7". But directly using that i am not able to locate the element from webdriver. I tried ...