I have two date fields. One field is from date and second one is to date.
While the cursor moving from second date field to submit button, I have to compare the two dates.
if from date greater than to date it has to display error and has to empty the field and has to focus.
My date format is:MM-DD-YYYY
first date is:08-10-2015 and secondate is:08-15-2015 , if the date is like this it has to do nothing.
Suppose, if is in reverse like,first date is:08-15-2015 and secondate is:08-10-2015, it has to display error. how to do ?
All 2 Replies
Be a part of the DaniWeb community
We're a friendly, industry-focused community of 1.21 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.