How to navigate a subframe inside a frameset using Selenium WebDriver?

前端 未结 4 2188
梦谈多话
梦谈多话 2020-11-28 14:41

I need to get the result from the table \"td\". But before I can do that I need to navigate a frame that contains it. The frame is one of the frameset elements that belongs

4条回答
  •  Happy的楠姐
    2020-11-28 15:32

    You can switch directly to the frame you want with the xPath. Get the Xpath through the Developer console, then:

    driver.switch_to.frame(driver.find_element_by_xpath('html / frameset / frameset / frame[1]'))

提交回复
热议问题