Hey as long as we are talking about dates and times, I am going to need soon a method to determine if a block of time intersects with another. Specifically I will need to do this in an SQL query. I suppose the best way would be to store all dates in julian format, then have a query that, given savedStartDate and savedEndDate are columns in a table, goes something like :
select * where (startDate > savedStartDate and startDate < savedEndDate) or (endDate > savedStartDate and endDate < savedEndDate) Is that about right? Any other ideas? Bob On Jul 20, 2011, at 8:29 AM, James Hurley wrote: > Roger > > Is this what you are looking for? > > on mouseUp > set itemdel to ":" > put the long time into tTime > put char 1 to -4 of tTime into field 1 > convert tTime to dateItems > set the hms of me to tTime > countDown > end mouseUp > > on countDown > put the hms of me into temp > subtract 1 from item -2 of temp > --The dateItems will take care of the negative seconds > convert temp to dateItems > set the hms of me to temp > put temp into tDisplayTIme > put item -4 to -2 of tDisplayTIme into temp2 > replace "," with ":" in temp2 > put temp2 into field 1 > send countDown to me in 1 sec > --Change the "1 sec" to "1 Minute" when you are sure it works for you. > end countDown > > Jim Hurley > > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode