|  | Sending more than one object in the same makro |  | |
| | | Leif Thorsen |  |
| Posted: Sun Sep 21, 2008 4:09 pm Post subject: Sending more than one object in the same makro |  |
Is there a way to send 2 reports in the same using the command "SendObjekt" ?? When using the makro I only have the possibility to choose between one of all reports I have made but I am in a need to attache two of my reports. Thank You in advance for an answer |
| |
| | | Tony Toews [MVP] |  |
| Posted: Sun Sep 21, 2008 4:33 pm Post subject: Re: Sending more than one object in the same makro |  |
Leif Thorsen <LeifThorsen@discussions.microsoft.com> wrote:
| Quote: | Is there a way to send 2 reports in the same using the command "SendObjekt" ?? When using the makro I only have the possibility to choose between one of all reports I have made but I am in a need to attache two of my reports.
|
You can't send more than one Access object using SendObject. You will need to use VBA and another means of sending emails.
Microsoft Access Email FAQ LINK
Tony -- Tony Toews, Microsoft Access MVP Please respond only in the newsgroups so that others can read the entire thread of messages. Microsoft Access Links, Hints, Tips & Accounting Systems at LINK Tony's Microsoft Access Blog - LINK |
| |
| | | Tom Wickerath |  |
| Posted: Sun Sep 21, 2008 4:34 pm Post subject: RE: Sending more than one object in the same makro |  |
| |  | |
Hi Leif,
No. The SendObject method can only be used to send one object at a time. One option might be to create a new blank report, and then insert the two reports as subreports to this new report. That way, when you send the new report, it would include the content of both reports.
Another method would involve first exporting your report to a folder on your hard drive, using the appropriate format (for example, the portable document format [.pdf] or the Microsoft Access Snapshot format [.snp]). Then use VBA code with Outlook (not Outlook Express) to send the saved files to the reciepient. An example of doing that is shown on page 19 of a document that I call Access Links.doc. You are welcome to download a zipped copy from here:
LINK
Look for the topic: "Late Bound code for Outlook to send several file attachments."
Tom Wickerath Microsoft Access MVP LINK LINK __________________________________________
"Leif Thorsen" wrote:
| Quote: | Is there a way to send 2 reports in the same using the command "SendObjekt" ?? When using the makro I only have the possibility to choose between one of all reports I have made but I am in a need to attache two of my reports. Thank You in advance for an answer |
|
| |
| | | Leif Thorsen |  |
| Posted: Sun Sep 21, 2008 4:46 pm Post subject: Re: Sending more than one object in the same makro |  |
"Tony Toews [MVP]" wrote:
| Quote: | Leif Thorsen <LeifThorsen@discussions.microsoft.com> wrote:
Is there a way to send 2 reports in the same using the command "SendObjekt" ?? When using the makro I only have the possibility to choose between one of all reports I have made but I am in a need to attache two of my reports.
You can't send more than one Access object using SendObject. You will need to use VBA and another means of sending emails.
Microsoft Access Email FAQ LINK
Tony -- Tony Toews, Microsoft Access MVP Please respond only in the newsgroups so that others can read the entire thread of messages. Microsoft Access Links, Hints, Tips & Accounting Systems at LINK Tony's Microsoft Access Blog - LINK
|
Thank Yuo for Your rapid answer. |
| |
|
|