RE: Need to Locate JavaScript Link

a Javascript link appear in a child pop up window when i Click on an image in Parent Window.

I need to locate this webElement. Here is my code.

driver.findElement(By.xpath(“html/body/form/div[2]/a”)).click();
JavascriptExecutor executor = (JavascriptExecutor)driver
executor.executeScript(passBack(v[1], v2[1]).click()”;

The link in a new popup window which i am not able to locate.

rehanshahid Train Asked on November 2, 2015 in Selenium WebDriver.
Add Comment
3 Answers

below is the HTML of the link.

<a href=”javascript:passBack(v[1], v2[1]);>583 – WALNUT DISTRIBUTION CENTER</a>.

I am trying to click on this link with linkText name =583 – WALNUT DISTRIBUTION CENTER. but does not work

Train Answered on November 3, 2015.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.