Click to See Complete Forum and Search --> : Timers
Compwiz
Nov 7th, 1999, 08:46 AM
Does a timer with a smaller interval take up more memory than one with a larger one? (i.e. 1 vs. 1000)
------------------
Tom Young, 14 Year Old
tyoung@stny.rr.com
ICQ: 15743470
AIM: TomY10
PERL, JavaScript and VB Programmer
DiGiTaIErRoR
Nov 7th, 1999, 11:32 AM
I would think it would depend on the function of what the timer is doing like if it was just keeping time you could use 500 or so I'ld just make the interval as high as possible like you wouldn't keep time with a 1 interval.
------------------
DiGiTaIErRoR
prestodsi
Nov 7th, 1999, 08:49 PM
It depends on what the timer is doing in your code. Remeeber that the timer executes your code at every tic, so you need to manage your memory by analyzing what you want to have done.
if the timer will execute your code only once,disable it programatically. Then enable it again, also programatically, when you need it later
------------------
Paul Stermann
DSI-Houston
ShadowCrawler
Nov 8th, 1999, 05:40 AM
It's not that it takes up more memory, but a minute bit of processing power. The code it executes is what determines the memory footprint, along with how much processing it requires. I've written many apps with a Timer.Interval set to 1, but because it's not executing much code, you don't even notice.
------------------
(¯`·.¸¸.·´¯`·->ShadowCrawler<-·´¯`·.¸¸.·´¯)
Teenage Programmer
Visual Basic, HTML, C++, JavaScript
http://welcome.to/X12Tech
Email: craigkovatch@compuserve.com
ICQ#: 9872708 (http://wwp.mirabilis.com/9872708)
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.