April 28, 2024, 09:11:13 PM

News:

IonicWind Snippit Manager 2.xx Released!  Install it on a memory stick and take it with you!  With or without IWBasic!


Max timer setting

Started by LarryMc, February 25, 2007, 06:08:51 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

LarryMc

Anyone know what the max number a starttimer command can be given?
LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library

Parker

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.

LarryMc

Not the number of timers but the duration.
LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library

Ionic Wind Support Team

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?
Ionic Wind Support Team

LarryMc

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
LarryMc
Larry McCaughn :)
Author of IWB+, Custom Button Designer library, Custom Chart Designer library, Snippet Manager, IWGrid control library, LM_Image control library

Parker

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.