public ss selectType(String Type){
WebElement myElement = driver.findElement(By.xpath ("//select[@data-val-required='Type is Required.']"));
Select dropdown= new Select(myElement);
dropdown.selectByVisibleText(Type);
System.out.println("Select type" + Type);
return this;
}
selectSRype("Enroll");
When I run my test, it should select the value Enroll from the drop down field. But it does not. I also don't get any error. It did print the message in console too. During run, I can see field is being clicked by value is not being selected. How can I select a value from drop down field?
Please advise.
--
You received this message because you are subscribed to the Google Groups "Selenium Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to selenium-users+unsubscribe@googlegroups.com.
To post to this group, send email to selenium-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/selenium-users/b7f0dabd-d110-4552-bc3d-f85b274b64d2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.