Email multiple reports

Mrs.Meeker

Registered User.
Local time
Today, 11:21
Joined
Mar 28, 2003
Messages
172
I would like to click on button on a form to send an email containing 3 reports. I used the following:

Private Sub CmdEmailScoreReports_Click()
On Error GoTo Err_CmdEmailScoreReports_Click

Dim stDocName As String

stDocName = "RptNegativeResponsesByProject"
DoCmd.SendObject acReport, stDocName

stDocName = "RptPositiveResponseswithNotesByProject"
DoCmd.SendObject acReport, stDocName

stDocName = "RptScoreResultsByProject"
DoCmd.SendObject acReport, stDocName


Exit_CmdEmailScoreReports_Click:
Exit Sub

Err_CmdEmailScoreReports_Click:
MsgBox Err.Description
Resume Exit_CmdEmailScoreReports_Click

End Sub

Simply adding this addition lines had no effect and only one report is attached to the email. How do I write my code to include all 3 reports?

thanks!!!!
 
I don't believe this is possible using the sendobject command. What you may have to do is make one main report and make the 3 reports you want subreports of the main report. Then use the sendobject to send the main report.
 
This is a VERY good idea! thanks for the advise!!!

:D
 

Users who are viewing this thread

Back
Top Bottom