# Revision history [back]

I realised I don't need to retrieve the locale date setting; there's an easier (if not very elegant) way. I've found a simple answer to the problem with this (what I've termed) tripwire code:

dim testDate    as date
testDate=cDate("21/01/16")


On a UK system this statement will work because the default date format is D/M/Y On a US system this statement will fail because the default date format is M/D/Y

I have discovered that the 'problem' with dates ONLY appears when you attempt to coerce a date with cDate or you input a date in an unacceptable format. Internally dates are held as a decimal number and when displayed, unless reformatted, will default to whatever the default format is.

BTW: I rejected a universal solution which would be to insist that all users adopt the ISO standard. I don't think this is a realistic approach. My attitude to systems design is that the system should adapt to the user and not the other way around.