Run a Query Hidden/Invisible

  • Thread starter Thread starter Walter Steadman
  • Start date Start date
W

Walter Steadman

Is there a way to run a query hidden? Like when the DB Opens, and I have a
Form Open as the starting form. Is there a way to put something in the On
Open event of the form to have it run an update query invisible? I am
checking for a certain date, and if a record meets the criteria, it will
change the Active Checkbox from True to False. The query works fine, but I
want it to open automatically and invisible to the user.

TIA

Wally Steadman
US Army in Iraq
 
Walter Steadman said:
Is there a way to run a query hidden? Like when the DB Opens, and I have a
Form Open as the starting form. Is there a way to put something in the On
Open event of the form to have it run an update query invisible? I am
checking for a certain date, and if a record meets the criteria, it will
change the Active Checkbox from True to False. The query works fine, but I
want it to open automatically and invisible to the user.

Action queries (Update and Append) are executed, not opened. If you use a
command to execute the query nothing will appear on the screen. My preference
would be...

CurrentDB.Execute "QueryName", dbFailOnError
 
Thanks Rick. Did not know that about Update and Append Queries. Appreciate
the help.
 
Back
Top