'没有这样的元素:无法找到元素:{“ method”:“ class name”,“ selector”:“ choose-container”
任何人都可以建议我在当前代码中进行任何更改
IWebElement Element = driver.FindElement(By.ClassName("chosen-container"));
selectionframeElement.Click();
element = driver.FindElement(By.XPath("//td[@id='ddlType']"));
selectionframeElement.Click();
IWebElement webElement = selectionframeElement.FindElement(By.TagName("input"));
Thread.Sleep(3000);
element.Click();
try
{
foreach (var liitem in ulList.FindElements(By.TagName("text")))
{
if (liitem.Text.Equals("Phone Up"))
liitem.Click();
}
Thread.Sleep(5000);
}
catch (Exception)
{
// throw;
}