You can convert any given date to dateItems. Then you can use dateItems to present the date in any format you like. A date converted to dateItems will give you the following list of items:
the year the month number the day of the month the hour in 24-hour time the minute the second the numeric day of the week where Sunday is day 1, Monday is day 2, and so forth All according to the Dictionary. To be sure that any valid date format is recognized as a date when you read in the date you will like to convert, it is best to ask for the system date or set the useSystemDate to true, as this will make all valid date formats convert to dateItems. Best regards Tore Nilsen > 28. okt. 2020 kl. 22:58 skrev Graham Samuel via use-livecode > <use-livecode@lists.runrev.com>: > > A quick test seems to show that the DateFormat can’t be changed by a ‘set’ > command. > > How then can I force a date to be in a given format? I’m really thinking of > the difference between US and European dates, i.e > > d/m/y versus m/d/y > > Obviously for some types of use, an LC program should be able to force the > format for consistency’s sake, regardless of where in the world it’s being > run. > > Can it be done? > > Graham > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode