Anyone know what the max number a starttimer command can be given?
I checked MSDN and I couldn't see any max value, I assume it's limited just by the total number of unsigned integers, but that's a lot of timers.
Not the number of timers but the duration.
Maximum of an integer as far as I know. Unless Microsoft has some imposed limit on it.
Why not give us some more information, like... why are you asking? Are you having prolems?
I'm playing around with triggering events to happen daily, weekly, monthly, etc. but not at a specific time.
I know I can:
1) use one short timer duration and increment counters then test for a given value;
2) use multiple long duration timers and no inc. counters
3) use a combination of 1 and 2.
So, I was just curious as to the biggest duration I could pass to a timer.
One hour=3,600,000
One day=86,400,000
One week=604,800,000
One year = 31,449,600,000
Like I said, just curious.
Larry
Instead of waiting for a year-long timer, I'd look into using the windows scheduling service. You can probably do that with COM, but you can look up the AT command (at /help) for scheduling jobs at specific times. You can retrieve the current time and just add a month, day, year, or however long to that. It's a lot more efficient than using a timer like that I would think.