Re: Days and hours
Re: Days and hours
- Subject: Re: Days and hours
- From: "Nigel Garvey" <email@hidden>
- Date: Wed, 19 Oct 2005 21:44:56 +0100
Bernard Azancot wrote on Wed, 19 Oct 2005 13:09:21 +0200:
>> From: Michelle Steiner <email@hidden>
>> set mon to (choose from list {January, February, March, April, May,
>> June, July, August, September, October, November, December} with
>> title "Employment month" with prompt "Enter the month for which you
>> wish to compute hours worked." default items {month of working_month})
>> try...
>
>I would like to know how could I translate this list in a french user
>friendly list and make the script function without issue.
>
>{Janvier, Fevrier, Mars, Avril, Mai, Juin, Juillet, Aout, Septembre,
>Octobre, Novembre, Decembre}
Does this do it?
set d2 to date ("1 1 1" as string) -- January on any machine.
set theDigits to "123"
set monthWords to {}
considering case
repeat 12 times
set d1 to d2
set d1's day to 28
set d2 to d1 + weeks -- Same weekday, following month.
set w1 to words of d1's date string
set w2 to words of d2's date string
repeat with i from 1 to (count w1)
set thisWord to item i of w1
if not ((thisWord is item i of w2) or (character 1 of thisWord is
in theDigits)) then
set end of monthWords to thisWord
exit repeat
end if
end repeat
end repeat
end considering
choose from list monthWords
NG
_______________________________________________
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