I have an application that converts the following invalid dates, with only two-character years into a valid date format automatically while the user's filling out the form:
(NOTE: The application is only in-use by UK organisations, so the dates are all UK format only)
01/01/01 to 01/01/2001 14/05/58 to 14/05/1958 21/11/25 to 21/11/2025
It works out which century to use based on a semi-arbitrary threshold on
2050, so if a user inputs
49, they'll get
2049, but if they enter
50 they'll get
The conversion happens when the user tabs off the field and is visible immediately.
I recently received a complaint from one user who said they entered
10 and got
2010, but entered
27 and got
2027, not the
1927 they were hoping for. Their reasoning was that the
2027 was in the future, and should therefore convert to
1927 instead (because the future date was impossible).
I think in the long run, I'd love to just get rid of this functionality - I have no idea what's going to happen when we hit 2050... But in the short term, is there a way to alter the existing, basic, algorithm to make it more intuitive or user-friendly?
Background (not related to question)
For those interested, the user can also pick the date from a list of dates, or enter a date in a few other formats with various dashes and slashes and the system will make similar adjustments. If the system is unable to make an adjustment to the valid date format, it alerts the user via a visual cue and validation on the page fails.
The uses of the terms "valid" and "invalid" here are purely in relation to the application and have no bearing on any particular national or international date format.
Similar to this question: Date picker subtleties: Input year by using numeric keys