public void HomeValueType(string value) { DdlHomeValueType.Click(); new WebDriverWait(PublicPandM.PropertiesAndMethods._driver, TimeSpan.FromSeconds(3)).Until( ExpectedConditions.ElementExists( By.XPath("/html[1]/body[1]/div[2]/section[1]/form[1]/fieldset[2]/div[1]/div[4]/div[1]/div[2]"))); var lists = ListHomeValueType.FindElements(By.TagName("div")); foreach (var item in lists) { if (item.Text == value) { item.Click(); } } }
//Set Home Value Type void HomeValueType(string value) { DdlHomeValueType.Click(); new WebDriverWait(Driver.driver, TimeSpan.FromSeconds(3)).Until( ExpectedConditions.ElementExists( By.XPath("//div[@class=\'menu transition visible\']"))); var lists = ListHomeValueType.FindElements(By.TagName("div")); foreach (var item in lists) { if (item.Text == value) { item.Click(); } } }