I have bunch of elements with class X.
some elements have class Y also (ie both X and Y)
how do I select set of elements only have X with partial class name?
below is my example HTML
<td class="dxeCalendarDay_Office2010Blue dxeCalendarOtherMonth_Office2010Blue" savedcursor="[object Object]" style="cursor: pointer;">29</td>
<td class="dxeCalendarDay_Office2010Blue" savedcursor="[object Object]" style="cursor: pointer;">4</td>
I could select all of them using
By.cssSelector("[class^='dxeCalendarDay']");
The class prefix "_Office2010Blue" will change at run time
But I need to exclude elements which having "dxeCalendarOtherMonth..."
probably something like.....
By.cssSelector("[class^='dxeCalendarDay'].Not:([class*='dxeCalendarOtherMonth'])");
what is the correct syntax?
(By.cssSelector("[class^='dxeCalendarDay']:not([class*='dxeCalendarOtherMonth'])")