update query confirmation boxes?

G

Guest

hello all,

When running an update query, is it possible to customize the confirmation
message boxes that come up during the update?

Thanks,

Brook
 
V

Van T. Dinh

Yes if you run the Update Query by code. You simply present the MsgBox to
the user before actually running the Query.
 
G

Guest

Thank you for the information,

Can you elaborate on how to present the MSGbox to the user before
running the query?

Can I override the systems confirmation boxes?

Brook
 
R

Rick Brandt

Brook said:
Thank you for the information,

Can you elaborate on how to present the MSGbox to the user before
running the query?

Sub RunAQuery

If MsgBox ("Are you sure", vbYesNo) = vbYes Then
CurrentDB.Execute "QueryName", dbFailOnError
End If

End Sub
Can I override the systems confirmation boxes?

Using the execute method to run the query as above doesn't produce any
confirmation boxes.
 
R

Rick Brandt

Brook said:
Hello Rick....

Where do I place the code that you have suggested?

Brook

Wherever you want the query to run. Typically the click event of a command
button on a form.

If your desire was to have something like this happen when they launch a query
from the db window then that is not possible.
 

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