In a form, the user is required to choose date and time in a picker, thereafter choose other fields and hit 'Done'.

I have a datetime picker that displays a date and time by default. Moreover, the user is allowed to type and erase the date and time. (by using keys and backspace). In case a user doesn't fill an entire date as an entry. I have to choose between either of the following two options:

  1. Whether the date time picker should auto-fill the recent value on the user's behalf?

  2. Or should the input field stay half-filled and then throw a 'Validation Error' like "Please Choose a Date and Time" ?

2 Answers 2


Depending on the context of the DateTime-picker I'd suggest considering adding a button next to it to populate the picker with a specified date (again, depending on context).

The button should be clearly defined so that the user knows what it does, use date.now(), a pre-selected date depending on the context or whatever. This would allow the user a way to easily add the date to the picker or decide to add the date manually.

When it comes to Dates / Times it's always (in my opinion) important to use some sort of validation and formatting as regions etc have different formats etc. Simply add an invisible label next to the picker that shows up in red forecolor to display what the error might be and what the user can do to fix it.

My biggest suggestion is to be clear with the requirements to the user, make it as easy as possible to fulfill those requirements - but don't dumb it down for him / her!


This depends on the context of the date picker.

If your users are likely to want to regularly use today's date then you automatically populate with todays date.

If, however, using today's is not possible (or is problematic for some other reason) then you need to throw an error.

I would recommend some simple testing with your target users to find out what they want to see.

(You will also need to test any error systems with them too so that you can be sure that they understand what is required from them when an error occurs.)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.