I am trying to email a report to different recipients. The report has different data according to the recipient.
I've created a macro to open the report and in the "where condition" I put in the criteria. Which all works. After it opens, the next step in the macro is to Sendobject, which I have setup to whichever recipient. The next step is to close the report.
Then the next step is to open the report again, with the "where condition" set up for the next recipient. and so on.
Each recipient has the:
OPEN
SENDOBJECT
CLOSE
The report is ran from a form that has a date range on it and a button to run the macro.
It will run the first set of OPEN, SENDOBJECT, CLOSE and send it. Anything after that it will run but not send.
If I run them individually, it will do the first but none of the others. I have to close the database, open it again and then it will run the next. I don't think I want to have close the database between each.
I have 13 recipients and would like this to be automated. Any suggestions?
Thanks in advance!
I've created a macro to open the report and in the "where condition" I put in the criteria. Which all works. After it opens, the next step in the macro is to Sendobject, which I have setup to whichever recipient. The next step is to close the report.
Then the next step is to open the report again, with the "where condition" set up for the next recipient. and so on.
Each recipient has the:
OPEN
SENDOBJECT
CLOSE
The report is ran from a form that has a date range on it and a button to run the macro.
It will run the first set of OPEN, SENDOBJECT, CLOSE and send it. Anything after that it will run but not send.
If I run them individually, it will do the first but none of the others. I have to close the database, open it again and then it will run the next. I don't think I want to have close the database between each.
I have 13 recipients and would like this to be automated. Any suggestions?
Thanks in advance!