Re: monthNumber (was: Create a folder with today's date...)
Re: monthNumber (was: Create a folder with today's date...)
- Subject: Re: monthNumber (was: Create a folder with today's date...)
- From: Nigel Garvey <email@hidden>
- Date: Wed, 13 Feb 2002 12:30:09 +0000
Richard Morton wrote on Wed, 13 Feb 2002 10:17:03 +1100:
>
Note that 'shortDateMostCompact' uses the very cool "Bangers & Mash"
>
(sorry Nigel ;-) method for adding leading zeroes:
Oh please! I'm a vegetarian....
>
Anyway, a search of my shortDate vault revealed the handler below, which
>
I thought some people might find interesting. It was posted here (or on
>
macscrpt) by John Delacour, probably a couple of years ago.
Shortly before he stopped posting his terse, often irritable, but
thoroughly well informed wisdom to either list. And his sandals were
never found.... :-(
>
ShortDate
>
afficionados will note it's ancestry. I didn't test it for speed.
>
>
on getDate(d, sep, zeros, century, yearFirst)
>
set {d1, aDay} to {d, 1314864}
However, his variable names sometimes left something to be desired...
aDay / days
--> 15.218333333333
>
copy d1 to d2
>
set d2's month to January
>
set y to d1's year as string
>
set d to d1's day
... as did their variable meanings! ;-)
NG
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.