Re: Display Form or MsgBox while query is running

  • Thread starter Albert D. Kallal
  • Start date
A

Albert D. Kallal

JimP said:
I have a lengthy append query that runs when WindowHide is set to yes. The
problem is that users have no way of knowing that the query is running
because the status bar is not displayed.

How can I force a form to open before the query runs and then close when
it finishes without user interaction?

1. Simply opening the form before the query runs, partially loads the form
while the query runs.

Just open the form, but place a doevents right after.

Eg:

docmd.OpenForm "MyPleaseWaitMessageForm"
doevents

run long query here....

docmd.Close "MyPleaseWaitmessageForm",acForm

msgbox "done"
 
P

Pete D.

You could use the form timer event to animate a picture. I used it once,
totally usless function but I thought it was fun. I used a tiny police car
beacon with 3 overlaid images of it with the bright part in diffifent
postions and alternated visible with a case statement for the three
pictures. Looked like the light was revolving. You could do something with
a couple of text boxes or such. Might slow Access down a little but keeping
the picture/textbox small and the timer reasonable I didn't notice much.
 
P

Pete D.

Well I know queries don't reveal events so the progress bar cannot be used
but I thought the timer event on a form would. Maybe if the query was
running on sql server it would as the server could process the query without
access. I may have wasted your time on this one. When I did this mine ran
the queries on the timer to update a status board and they were not that
time consumming. Maybe out of luck on this. Sorry, Pete
 
P

Pete D.

Only one other thing I can think of and that would be a control/activex
control of somesort that plays an animation. Start it before the query runs
and close it when query completes. There are animation players for access
forms but I havn't played with them since...gee I think it was Access 97.
 
A

Albert D. Kallal

JimP said:
Well, I am using the "OnTimer" event to change the visible property of a
label from (false, true, false..), but the query running in the background
keeps the form from getting refreshed. I need to find a way to force the
form to refresh.

You would need a doevents in that timer loop if this was going to work. I
don't believe when the query is running that any processing is released to
any part of access. You could try putting in an doevents in your timer code,
but my spiders sense tells me that it will not work anyway...
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top