Dangers with using the date mask
Using a normal date mask on your date-fields will cause some very strange behaviour of your programs.
Most users of dataflex programs will do a lot of data-entry, this means that they will type pretty much, they know what they typed and as a result they will not always watch at the screen for the results.
This implies that if the program has some automatic conversion to correct dates it
should not make any mistakes.
The table below will show what happens if the user enters ambiguous dates. The
results of various date settings in the windows regional settings are shown.
Userinput | d-M-yy | M-d-yy | dd-mm-yyyy | mm-dd-yyyy |
2271999 22799 1121999 212199 2121999 771999 |
22-12-99 22-12-09 11-12-99 21-12-99 21-12-99 31-12-99 |
12-31-99 12-31-09 11-21-99 12-21-99 12-21-99 12-19-99 |
22-12-0999 22-12-2009 11-12-0999 21-12-1999 21-12-0999 31-12-1999 |
12-31-0999 12-31-2009 11-21-0999 12-21-1999 12-21-0999 12-19-1999 |
Notes:
- With the two digit years in the regional settings a year-value of 0999 is displayed as
"99" as long as the field doesnt have the focus. This means that it will
look to the user that he entered "1999" while in fact there is an error in his
date of a 1000 years.
- Users that are not stretching the date masks to its limits will not experience these
problems "7-7-99" and "070799", or "7-7-1999" all are
correct dates and will be correctly interpreted.