D
DeanT
I want to send email with 2 report attachments. My coding is below. The
problem I have is this coding only attaches the first report. How do I add in
the 2nd report into the coding. I only want one email sent with both reports
attached.
Function Send_RC()
On Error GoTo Send_RC_Err
DoCmd.OpenReport "Record of Complaint", acViewPreview, "",
"[Complaints]![ComplaintNumber]=[Forms]![ComplaintForm]![ComplaintNumber]",
acNormal
DoCmd.OpenReport "AckLetter", acViewPreview, "",
"[Complaints]![ComplaintNumber]=[Forms]![ComplaintForm]![ComplaintNumber]",
acNormal
DoCmd.SendObject acReport, "Record of Complaint",
"SnapshotFormat(*.snp)", "", "", "", "Consumer Complaint", "", True, ""
Send_RC_Exit:
Exit Function
Send_RC_Err:
MsgBox Error$
Resume Send_RC_Exit
End Function
Thanks for any help.
problem I have is this coding only attaches the first report. How do I add in
the 2nd report into the coding. I only want one email sent with both reports
attached.
Function Send_RC()
On Error GoTo Send_RC_Err
DoCmd.OpenReport "Record of Complaint", acViewPreview, "",
"[Complaints]![ComplaintNumber]=[Forms]![ComplaintForm]![ComplaintNumber]",
acNormal
DoCmd.OpenReport "AckLetter", acViewPreview, "",
"[Complaints]![ComplaintNumber]=[Forms]![ComplaintForm]![ComplaintNumber]",
acNormal
DoCmd.SendObject acReport, "Record of Complaint",
"SnapshotFormat(*.snp)", "", "", "", "Consumer Complaint", "", True, ""
Send_RC_Exit:
Exit Function
Send_RC_Err:
MsgBox Error$
Resume Send_RC_Exit
End Function
Thanks for any help.