• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Localize weekdays
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Localize weekdays


  • Subject: Re: Localize weekdays
  • From: jj <email@hidden>
  • Date: Fri, 28 Jan 2005 09:54:38 +0100

>>> (current date) as text --> "viernes, 28 enero 2005 00:08:57"
>>>
>>> But I don't think I can pick "viernes" from this string, since I don't know
>>> if word-of-dateAsText-which-is-not-a-number is a weekday or a month name...
>>
>> Right. So ask for the weekday specifically ;)
>>
>> weekday of (current date)
>> ->Viernes
>
> Did you really did test that? I don't believe it. You're making it up, for
> reasons known best to yourself. Can't be bothered to test?
>
> 'weekday', like 'month', results in a _constant_ which looks like the
> English name of the weekday. No matter what you set the International Date
> System Preference to, the result is always Thursday, Friday, etc. Never,
> ever Viernes.

True, and this should be (if Apple implemented it) a string result:

pseudo-code:
set w to weekday of (current date)
--> Friday
w as text
--> "viernes"

If this is time for requests, I would extend the "month as number" new
feature to weekdays, as well as coercion-to-localized-string of all date
constants (minutes as string --> "minutos"; January as string --> "enero";
etc.), and even every constant which is "part of the real world" and has its
context out of AppleScript (pounds as string --> "libras"; degrees Celsius
as string --> "grados Celsius")... ;-)


jj

--
http://www.macscripter.net/
http://www.osaxen.com/


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Re: Localize weekdays (From: Paul Berkowitz <email@hidden>)

  • Prev by Date: Re: definition list recommendations?
  • Next by Date: Re: Saving BBEdit Text Files
  • Previous by thread: Re: Localize weekdays
  • Next by thread: Re: Localize weekdays
  • Index(es):
    • Date
    • Thread