Re: Anyone got the time?
Re: Anyone got the time?
- Subject: Re: Anyone got the time?
- From: Jack Miller <email@hidden>
- Date: Wed, 21 Jul 2004 18:00:12 +0100
Thanks. It helped a lot!
Also, what is the syntax of delay? I tried delay, and then a number
(for seconds) but I haven't used applescript since I was about 9, and
my memory is a tad rusty :). Thanks for all the help though!
On 21 Jul 2004, at 08:00, Andrew Oliver wrote:
>
This is easily done using AppleScript's 'current date' and a little
>
math:
>
>
set theTime to time of (current date)
>
set theHour to theTime div hours
>
>
'time of (current date)' returns the number of seconds since midnight.
>
A
>
simple division by hours returns a number from 0 to 23 depending on
>
the hour
>
which you can plug into the rest of your script.
>
>
Andrew
>
:)
>
>
On 7/20/04 11:28 PM, "Jack Miller" <email@hidden> wrote:
>
>
> Hi,
>
>
>
> I'm trying to code a little applescript to open a program if the time
>
> is not between 8 am and 12 pm (0800 to 1200). I've got the rest of the
>
> script done, I just need to know what I can use to get the system time
>
> (not the whole lot in that
>
> format-that-I-can't-really-remember-that-includes-the-data...)
>
>
>
> Time by itself (without caps) is recognition, but both the finder and
>
> the app that I want to open can't get it.
>
>
>
> Should I go back to obj-c?
>
>
>
> Many Thanks,
>
>
>
> Jack Miller
>
> ===================
>
> All copyrights are property of their respective owners.
>
> *Insert disclaimer here*
>
>
>
> [demime 0.98b removed an attachment of type
>
> application/pkcs7-signature which
>
> had a name of smime.p7s]
>
> _______________________________________________
>
> 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.
>
>
>
>
Many Thanks,
Jack Miller
===================
To err is human. To REALLY foul things up takes a computer....
_______________________________________________
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.