SendObject to send email

G

Guest

I was reading some previous posts about how to email a report using
sendobject however, when I attempt to do this I am getting an error saying
"can't open mail message" Below is the code I am using. Any help would be
appreciated. Thanks
Dim stDocName As String

stDocName = "rptReportName"

DoCmd.SendObject acSendReport, stDocName, , "user@address", , , "test
send", "test message", False
 
A

aaron.kempf

you should try this with a MACRO instead of a module first.

it's easier to make sure you've got all the args correctly.

other than that-- do you use outlook??

-Aaron
 
G

Guest

I think you are leaving out the report format:

DoCmd.SendObject acSendReport, "rpt_Whatever", acFormatSNP, "emailaddress",
, , "Subject", , True
 

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

Similar Threads


Top