selenium-webdriver To get out of a frame using Java


Example

To switch focus to either main document or first frame of the page. You have to use below syntax.

driver.switchTo().defaultContent();