Can a condition in a macro close a query?

A

Adam

I'm trying to automatically close a query if it's result returns zero
records. I have many queries running in one macro - not all will return
results all the time so i want to automatically close those with no results -
but i do want to run them.
What can i put in the conditional statement. I've tried and if statment but
i get an error.
 
C

Chris Reveille

In your conditions area of the macro on the line that runs
the query
DCount("*", "queryname") > 0

Chris
 

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