![](/img/trans.png)
[英]How to locate the element by href attribute using Selenium through Java
[英]How to locate and click on a link having javascript within the href attribute through selenium java
根據您共享的HTML ,單擊帶有AD04550的文本元素,您需要誘使WebDriverWait使所需的元素可單擊,並且可以使用以下解決方案:
linkText
:
new WebDriverWait(driver, 20).until(ExpectedConditions.elementToBeClickable(By.linkText("AD04550"))).click();
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.