Reputation: 325
I am trying to automate click on "tweet" button which is a part of iframe element.
I tried using css path, xpath but they are not working.
css path is like html.regular body.hcount div#widget div.btn-o a#b.btn span#l.label
i also tried xpath but it is not working.
Selenium ide provides "1" value for it, which is not worked by webdriver.
Please suggest some way.
Upvotes: 0
Views: 195
Reputation: 2202
You need to switch to the iframe element
driver.switchTo().frame(driver.findElement(By.id("frameId")));
//do your stuff
driver.switchTo().defaultContent();
If that is not the problem please provide futher information.
Upvotes: 1