Re: Changing current date format
Re: Changing current date format
- Subject: Re: Changing current date format
- From: "koenig.yvan" <email@hidden>
- Date: Sun, 19 Jan 2014 17:41:49 +0100
The (current date) format in a script automatically results in this output: Sunday, 19 January 2014 16:11:27 which is too much for an email subject.
I have tried: (do shell script "date +%Y-%m-%d") which produces 2014-01-19 which I can rearrange, but I cannot change the 01 to "January" by adding mmmm (as in Microsoft Office).
How can I set the current date to read: 17Jan2014 or 17 January 2014? and without the time
Thanks for any help
I read carefully your question so you may try to run this code :
(do shell script "date +%Y-%m-%d") --> 2014-01-19 set {y, m, d} to words of result --> {"2014", "01", "19"} (((d as number) - 2) as text) & text ((m * 3) - 2) thru (m * 3) of "JanFebMarAprMayJunJulAugSepOctNovDec" & y —> "17Jan2014"
Yvan KOENIG (VALLAURIS, France) dimanche 19 janvier 2014 17:40:49
|
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden