ensure query is complete

J

JT

I'm running queries in my code. Is there some command or code to insert
after kicking off the query to ensure they query completes before the next
line of code is executed? I have used a "DoEvents" in Excel and was
wondering if there is something similar in Access. Thanks for the
help............
 
M

Marshall Barton

JT said:
I'm running queries in my code. Is there some command or code to insert
after kicking off the query to ensure they query completes before the next
line of code is executed? I have used a "DoEvents" in Excel and was
wondering if there is something similar in Access. Thanks for the
help............


What kind of query?

What areyou doing with the result of the query.

An action query can be run synchronously by using the
Execute method.

If you are opening a recordset on a Select query, then
either you don't need it to complete or you need to use the
MoveLast method.

If you are opening a query is sheet view, then it doesn't
matter. Access manages the query's records as the user
interacts with the display.
 

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

Top