I have 2 elements on my webpage
element 1 : <div class="DynarchCalendar-day DynarchCalendar-day-othermonth" dyc-type="date" unselectable="on" dyc-date="19960429">
element 2 : <div class="DynarchCalendar-day" dyc-type="date" unselectable="on" dyc-date="19960501">
If i do
List<WebElement> DynarchCalendar_day = driver.findElements(By
.cssSelector("div.DynarchCalendar-day"));
I will get list of WebElements containing both element 1 and element 2
If i do
List<WebElement> DynarchCalendar_day = driver.findElements(By
.cssSelector("div.DynarchCalendar-day.DynarchCalendar-day-othermonth"));
I will get list of WebElements containing only element 1
What can i do to get Element 2 only ?