Selenium 2 - Switching focus to a frame that has no name/id

后端 未结 5 2014
轻奢々
轻奢々 2021-01-02 12:13

So right now I\'m trying to figure out how I can switch focus to a frame in Selenium 2 when the frame has no name or id? For a named frame I do:

driver.Switc         


        
5条回答
  •  情书的邮戳
    2021-01-02 12:29

    In selenium if you know that the relative location of the frame you should be able to use the selectFrame command with the string "relative=up" to move it up a frame e.g. selenium.SelectFrame("relative=up"); or to jump to the top frame use "relative=top"

提交回复
热议问题