Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Macro opens query that isn't in the list 1

Status
Not open for further replies.

Aubs010

Technical User
Apr 4, 2003
306
GB
I have a legacy database that I need to modify.

The OnClick event of one of the buttons calls the macro "resetstat". Within this macro are the following:

SetWarnings
WarningsOn = No

OpenQuery
QueryName = deletestat3
View = Datasheet
DataMode = Edit

OpenQuery
QueryName = up_2_to_1
View = Datasheet
DataMode = Edit

SetWarnings
WarningsOn = Yes


Bizarrely though, neither of the queries "deletestat3" nor "up_2_to_1"exist in anywhere I've looked... Any suggestions as to where they are? - It all works fine!

Many thanks :)


Aubs
 
I suspect if you remove the first set warnings line for testing you will see error messages about missing queries.

Turning off warnings supresses system warnings like asking you to confirm you really want to update or delete records... but I suspect it is alsow surpessing a message that says that the query can't be found.
 
Hi Lameid, I had thought of that one already but good suggestion... Amusingly it does not!

First: "You are about to run a delete query..."
Second: "You are about to delete 0 rows."
Third: "You are about to run an update query..."
Fourth: "You are about to update 0 rows."

So the queries must be there, somewhere?!

Aubs
 
try
menu -> tools->options->view->show->hidden objects

make sure it is checked
 
Thanks pwise, that's excactly where it was ;)


Aubs
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top