Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to display a timer form while a function is running ?

Status
Not open for further replies.

Schoen

MIS
Oct 13, 2009
2
BR
Hi,

I am facing a new situation over here, and hope some of you could give me a little help.

In my application there is a function. This function has a lot of calculations and call to others function.

What I wish to to is: When the function starts, I load a small form with a clock (current time) and a timer (elapsed time, that means current time less start time). So, when the function ends, I will save those information in my log table and close the form.

The form is working fine alone. But it just doesn't update its information while the function is running.

Is there a way to make it work ? I am not thinking about multithreading, what I know Ms Access can't handle, but maybe create an ActiveX control, or something.

Thanks.
 


Hi,

Check out the DoEvents Function.

Skip,
[sub]
[glasses]Just traded in my old subtlety...
for a NUANCE![tongue][/sub]
 
Hi Skip,
It doesn't work the way I need, because the clock and timer are codes in OnTimer event in the form. Since I ran a debug mode, I saw the code there isn't read, I mean, after load the form, the function get the control back and finish its codes. The focus doesn't return to the form.

In fact I put some DoEvents in code. What I only got is the form been loaded, but not updated.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top