• 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: Current date notation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Current date notation


  • Subject: Re: Current date notation
  • From: Paul Berkowitz <email@hidden>
  • Date: Fri, 11 May 2001 09:25:04 -0700

On 5/11/01 8:49 AM, "Marc K. Myers" <email@hidden> wrote:

>>>> I'm looking for the syntax on current date notation. I want to have
>>>> the output of "Current Date" as this:
>>>>
>>>> DD-MM-YYYY
>
> I haven't noticed any mention of my favorite way of formatting dates,
> Akua Sweets' "the clock". To get the desired format, all you need is:
>
> set x to the clock using form "%m-%d-%c%y"
> --> "05-11-2001"

Yes, Akua Sweets' 'the clock' is the most versatile of all the date osaxen.
As well as being able to specify precisely the format as above, with many.
many alternatives including full and abbreviated versions of months and
weekdays. years in 2-dii and 4-digit format, etc. (BTW the questioner here
actually wanted

"%d-%m-%c%y"
), it will also get you unknown users' own short format as set by their own
Date & Time control panel in their own regional language with the parameter

set x to the clock using system form "%d"

with adjustments for including seconds, or using abbreviated format in
regional language, etc. etc. All its alternative parameters also work for
any date, not just current date, by the simple insertion of 'from [date]':

set x to the clock from date "Saturday, November 3, 2001 12:00:00 AM"
using form "%d-%m-%c%y"

--"03-11-2001"

set x to the clock from date "Saturday, November 3, 2001 12:00:00 AM"
using system form "%e"

-- "Sat, Nov 3, 2001"
--
Paul Berkowitz


References: 
 >Re: Current date notation (From: "Marc K. Myers" <email@hidden>)

  • Prev by Date: Re: Impossible "If"?
  • Next by Date: Applescripting an export from Palm for FIleMaker
  • Previous by thread: Re: Current date notation
  • Next by thread: Network Assistant not scriptable??
  • Index(es):
    • Date
    • Thread