Posted on 2001-07-30
I actually asked this question a week ago and thought that the answer would work, however, I neglected to test it on a midnight rollover. Here is the deal ...
I populate 2 x ComboBoxes with all times from 6:00am, 6:30am etc through to 12:00am. I get the user to select a Suspend time and a Resume time. Let's say that the user wants a Timer to stop at 5:00pm and resume at 6:00am. Entering something like;
If Format$(Now,"hh:nn ampm") > Suspend and Format$(Now,"hh:nn ampm")<Resume then
That code will not work as it does not take the midnight jump into account and therefore, the Suspend time will not be greater. Can someone please point me in the right direction.