There is an inconsistency between Date and DateTime variables. With Date variables it is possible to use a "/" or a "-" as a separator. In the code below you can see that the result is the same.
With DateTime variables the code 'Move "01/01/2021" to dtTest1' delivers an invalid date in Europe and a valid date with US regional settings. With 'Move "01-01-2021" to dtTest2' it is the other way around.
Normally this wouldn't be a big problem, but currently I am developing on existing code in Europe for a project in the US. A bit more flexibility would be nice.
Code:
Object oButtonTEST is a Button
Set Location to 10 150
Set Label to "TEST"
Procedure OnClick
Date dTest1 dTest2
DateTime dtTest1 dtTest2
Move "01/01/2021" to dTest1
Move "01-01-2021" to dTest2
Move "01/01/2021" to dtTest1
Move "01-01-2021" to dtTest2
Showln "01/01/2021 - " dTest1
Showln "01-01-2021 - " dTest2
Showln
Showln "01/01/2021 - " dtTest1
Showln "01-01-2021 - " dtTest2
End_Procedure
End_Object
Code:
01/01/2021 - 01-01-2021
01-01-2021 - 01-01-2021
01/01/2021 - 1-0-0 00:00:00 // Wrong datetime in Europe
01-01-2021 - 1-1-2021 00:00:00