Non-English dates
Sarah
sarahr at genesearch.com.au
Sun Sep 14 22:38:00 EDT 2003
English-speaking, but using Australian formats:
[1] - yes, I get a valid date: 2004,6,1,2,0,0,3
[2] - Saturday is the last line of system weekDayNames although I have
heard that this is not always the case in Australian systems.
But, you can always identify weekends using the last item of the
dateItems structure. In the example above, the last item is 3, which
means Tuesday. (Sunday = 1, Monday = 2 etc.)
Cheers,
Sarah
On Friday, September 12, 2003, at 07:53 pm, FlexibleLearning at aol.com
wrote:
> Two date questions...
>
> I am trying to manipulate locale-independent dates by using dateItems,
> system weekdayNames and system monthNames. As I only have an
> English-based system, could any non-English system users help me out?
>
> [1] Date format convert...
>
> on mouseUp
> put line 6 of the abbrev system monthNames into tMth # or pick a
> number 1-12
> get (tMth & " 1, 2004") # or pick a year
> convert it to dateItems
> put it &cr& the result # Do you get "invalid date"?
> end mouseUp
>
>
> [2] Weekends...
>
> I understand it is dangerous to assume that line 7 of the system
> weekdayNames always refers to a Saturday and line 1 always refers to a
> Sunday.
>
> If this is the case, how do we reliably identify weekend dates?
More information about the use-livecode
mailing list