Re: Current date in standard additions dictionary
Re: Current date in standard additions dictionary
- Subject: Re: Current date in standard additions dictionary
- From: Andy Wylie <email@hidden>
- Date: Mon, 04 Jun 2001 13:12:28 +1200
on 4/6/01 4:07 AM, email@hidden at email@hidden wrote:
>
I want to get the time only from current date command, without the seconds
>
added. Does anybody know if/how I can do this? Thanks.
>
>
John
this should remove seconds regardless of formatting...
set t to time string of (current date)
if text item 5 of t is ":" then --check for colon if no leading zero
set x to 4
else
set x to 5
end if
if "M" is in t or "m" is in t then --12 or 24 hr
set t to {text 1 thru x, text -3 thru -1} of t
else
set t to text 1 thru x of t
end if
t as string
_____________________________ Andy