Need to deactivate timer function when access is minimised.

workmad3

***** Slob
Local time
Today, 23:15
Joined
Jul 15, 2005
Messages
375
Well, the title is fairly self explanatory :)

Basically, the DB i am working on has a set of calculations that are performed every 0.5s to keep values updated. There is no need for this to occur while access is minimised, and a couple of users are complaining that their computer slows down at times while access is running and minimised.

Is there a nice easy way to determine if access has been minimised? Does the form deactivate event get called when access is minimised? as this would probably be the easiest solution. Otherwise, does anyone know how to determine the active window easily using API calls?

Thank you.

Dave
 
Cannot you change the calculation from the On Timer event to a after update event of certain boxes??

Doing a calc every half a second, which is going to return the same answer 99% of the times seems wastefull anyway.
 
not really. There are a lot of dependancies I would need to work out, and then get them working across subforms and the like. I may have the time to do it eventually, but at the moment, it is working and the users want a quick fix to this problem.

Oh, and a quick bit of research showed that the activate and deactivate commands do not get fired for minimising access :(
 
I am sorry, but have no clue either what does get triggered on maximizing... or minimizing for that matter

You may have to resort to using API's or something
Then you have the issue of turning the calculations back on... Ouch... :eek:

I still say doing the on change events is easiest.... Tho time consuming to change probably....
 
Last edited:
heh :) a little time consuming. Theres about 200 odd controls that I would need to work out the dependancies between. It just seemed easier at the time to have it as a timer, guess thats coming back on me now :(
 
200 controls?? Geez.. On different forms... Ouch... Good luck
 

Users who are viewing this thread

Back
Top Bottom