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!

Displaying Program Status

Status
Not open for further replies.

qureshi

Programmer
Mar 17, 2002
104
AU
Hi,
I have developed a program which does a couple of things like Connecting to the database, Building the query according to the selection of the user, Processing the query and finally generating the report. I want to display the program status. Sometimes it take a very long time to complete the operation and the users think that its stuck.
I tried putting a form with a label that changes accordingly as the program passes through the various subs. All I get is a sort of transparent form and only displays the last operation i.e. in my case " Generating the Report"

Is there anyone who can get me out of this...

Thanks in advance.

Qureshi
 
Place the DoEvents statement in in the various subs. This allows the system to update. Hope this helps. If you choose to battle wits with the witless be prepared to lose.
[machinegun][hammer]
 
If you are using ADO to connect to the database you can also run your queries asynchronously so your program regains control while the database is processing the query. While you are waiting for the results you can keep the screen refreshed.

I had to do this in an application because the users would do a ctrl-alt-del and notice my program had a "Not Responding" in the task manager even though it was just processing a query. Running it asynchronously took care of that.

--Adam
 
Thanks for the input. I will try this on Monday and let u know the results.
Qureshi
 
The program worked fine with the DoEvents statement. Thanks a lot for the help.
One quick question for Adam is about Async queries. What is that can u please explain in a bit more detail. I have never used anything like that before, but i really like the idea and would like to experiment on that.

Thanks all

Qureshi
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top