append without getting the OK message?

K

kellie jones

I'm doing an append query within VB. (docmd.RunSQL sqlstmt)
Each time the query is run it asks "you are about to append 3 records" and
you have to click OK.
It's not a problem for me - but I don't want the users to see this prompt.
Can I run it without getting the prompt?
 
D

David Ferguson

Create a macro and on the first line use the 'Set Warnings' command and set
it to Off
Then add your query on the second line (Open Query)
Finally switch the prompt back on again using another 'Set Warnings' command
and set it to On
 

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