Xojo.Core.Date Question

I think adding a SQL format make sense
In conjunction with the other formats that already exist then you can get

 Totext( nil, Date.FormatStyles.SQL, Date.FormatStyles.SQL ) => equivalent to sqldatetime
 Totext( nil, Date.FormatStyles.SQL, Date.FormatStyles.None ) => equivalent to sqldate
 Totext( nil, Date.FormatStyles.None, Date.FormatStyles.SQL ) => there's no current equivalent 
 Totext( nil, Date.FormatStyles.None, Date.FormatStyles.None ) => an empty text (might as well)

And of course you can always add a locale & get whatever locale savviness you need + whatever other formats there are
You would end up with a lot more flexibility in the long run

BTW Does Date.FromText ONLY parse a string in teh format SQLDateTime… Given the number.FromText discussion I suspect that will be the case…

If so, is there or will there be an equivalent to ParseDate?

  • karen

I checked. Without option it gives the same result as date.SQLDateTime.

i use sqldate a lot when using listbox celltags to sort columns in date order.
not having this will break all my listbox code.

nice.