Hi Kandu, maybe you are trying to use GetSelectedCount()?
This function returns a number wich represent the number of different values selected in the field, so it returns zero when no values are selected.
Can you try this:
If one, more or no dates are selected, it will use the max date as the filter in set analysis. Or you want 2016-05-18 to be fixed?