Webdriver How to wait until the element is clickable in webdriver C#

前端 未结 4 1927
一整个雨季
一整个雨季 2020-11-29 08:56

There is a block Ui which covers all the elements for a few seconds after the Element have been generated in the browser because of this i facing a problem ,Since element ha

4条回答
  •  甜味超标
    2020-11-29 09:08

    Here's the code I use to check if it's clickable, else go to another URL.

    if (logOutLink.Exists() && ExpectedConditions.ElementToBeClickable(logOutLink).Equals(true))
                {
                    logOutLink.Click();
                }
                else
                {
                    Browser.Goto("/");
                }
    

提交回复
热议问题