"send" in 24-hours

Nicolas Cueto niconiko at gmail.com
Fri Sep 9 01:09:31 EDT 2011


Hello,

Two parts to my quandary, both relating to a school-chime stack I'm
making -- it plays a "chime" sound-file at hourly-intervals (more or
less) every weekday.

First, I recall reading once a warning about overly long "send"
values. In my stack's case, the "send A in X seconds" values are
either 60 minutes or 24-hours (converted to seconds).  What, if any,
concerns should I have when using "send" with such large values?

Second, I've got my stack to work with this set of time-values:

8:00
12:59
13:02
13:03

Obviously, I haven't tested a "send in 60 minutes" value. But, up to
the 13:03-chime, no problems.

Now, I want to test the jump in time from one day to the next -- say
between the 13:03-chime on Thursday and the 8:00-chime on the next day
Friday -- but, obviously, I do not want to wait a whole day for that.
I tried changing my PC's day-and-time settings, but no go.

If it helps, here is my script for calculating the "send" time
difference between 13:03 and 8:00 the next day:

put "13:30" into tTimeA
convert tTimeA to seconds
put "11:40" into tTimeB
convert tTimeB to seconds
convert tTimeB to dateitems
add 24 to item 4 of tTimeB
convert tTimeB to seconds
put abs(tTimeB - tTimeA) into tNextChimeTimeInSeconds
send "play chime" to me in tNextChimeTimeInSeconds seconds
set the cpPending of me to the result


Thanks.

--
Nicolas Cueto




More information about the use-livecode mailing list