Macro exports queries

J

juan

Hello,
I have a macro that exports 12 queries, one for each
Period 1-12. I have a parameter so that I can export what
I want. But not all periods have data since its base on
data. So is there a way I can run the macro but export the
periods that have data? For example, in May that's period
5 so if I run the macro it will export 12, but its just
waste of time.

Please advise if there's anything I can do to run certain
periods instead of all the periods.
Thanks,
Juan
 
S

Steve Schapel

Juan,

It is very difficult to answer your question without more detail about
how you have this set up, as regards what actions your macro ius
comprised of, and what you mean by the word "parameter". But in
general, it may be possible to use a Condition in your macro to test
whether there is any data in the query, before it does the export. An
example might be...
DCount("*","YourQuery")>0
 

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