heysupratim / material-daterange-picker

A material Date Range Picker based on wdullaers MaterialDateTimePicker
Apache License 2.0
1.33k stars 266 forks source link

Functionality to disable Future dates #58

Open NageswaraRaoCH opened 8 years ago

NageswaraRaoCH commented 8 years ago

how to disable future dates,i.e tomorrow on words....

nifrasismail commented 7 years ago

any update for this? How to disable the future dates?

yasirtahir commented 4 years ago

You can set the Max Date (In your case, it will be today), so that all the dates after the max date will be disable for selection.

dialog.setMaxDate(Calendar.getInstance()); // This will disable all the dates after today.

Similarly, there is an option to select Min Date to disable past dates. Please read more about them in the library.