A fix for Date.ShortDate shooting blanks

TLDR: Here’s a quick fix to old Date objects spitting out blank strings.

For those with legacy projects, which is most of us, you might know that any Date.ShortDate, Date.LongDate, etc fails on most non US date settings. It simply returns an empty string. Xojo has stated this won’t be fixed due to the date class being deprecated:

<https://xojo.com/issue/51602>

If you want your projects to work without having to convert all of your code to the new DateTime object, drop this module in and simply search and replace for say, .ShortDate and replace with .ShortDateWorking.

See the sample in the project

This does not require Xojo 2019r2+ and should work in most legacy Xojo’s.