macros - queries

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have made a macro which consists of a couple of make table and delete
queries. When I run the macro, every time the macro hits one of these
queries, it asks me to validate whether its OK to make or delete the table
just as it would have if the query had been running on its own. Is there a
way to turn off this validation so that the macro runs till its without
requiring prompting
 
Hi Neeraj,

Very easy to do. All you need to do is insert an action at the beginning:

Action = SetWarnings
Value = No

Then, after the last action query, insert the opposite:

Action = SetWarnings
Value = Yes

However, a warning is in order here. If any single line of your macro fails
to execute properly, the macro will terminate and warnings will not be turned
back on. To avoid this problem, developers use VBA code instead of macros.

If my answer has helped you, please answer yes to the question that reads
"Did this post answer the question?" at the bottom of the message thread.


Tom

http://www.access.qbuilt.com/html/expert_contributors.html
__________________________________________

:

I have made a macro which consists of a couple of make table and delete
queries. When I run the macro, every time the macro hits one of these
queries, it asks me to validate whether its OK to make or delete the table
just as it would have if the query had been running on its own. Is there a
way to turn off this validation so that the macro runs till its without
requiring prompting
 
Back
Top