Fix error with allowSelectionofSelectedDate

allowSelectionofSelectedDate and AutoClose did not work together