Re: Some date math
Re: Some date math
- Subject: Re: Some date math
- From: Michelle Steiner <email@hidden>
- Date: Mon, 24 Feb 2003 18:22:54 -0700
On Monday, February 24, 2003, at 05:56 PM, John Delacour wrote:
Does anyone know how to get the date of yesterday.
3get current date2 will get the current day. Fine.
3get current date - 1 displays also the current date. So what can I
do?
(current date) - (60 * 60 * 24)
Why do all that math?
Applescript has predefined time values.
minutes = 60
hours = 3600
days = 86400
weeks = 604800
For example, the time two weeks, three days, five hours, nine minutes,
and ten seconds from now can be expressed as
current date + 2 * weeks + 3 * days + 5 * hours + 9 * minutes + 10
--> date "Thursday, March 13, 2003 11:30:04 PM"
--
"There's some good in the world, Mr. Frodo, and it's worth fighting
for."
_______________________________________________
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.