java - How to compare user selected date with from and to date in Android? -


this question has answer here:

i want compare user selected date date , date. e.g.,

from date : 2017-25-07 date   : 2017-31-07 selected date : 2017-27-07 

so want check selected date in range between date , date.

you can compare 3 dates below code

if(!fromdate.after(selecteddate) && !todate.before(selecteddate)) {   //fromdate <= selecteddate <= todate } 

Comments

Popular posts from this blog

html - How to set bootstrap input responsive width? -

javascript - Highchart x and y axes data from json -

javascript - Get js console.log as python variable in QWebView pyqt -