Send action (Outlook)

DeonO

Novice Programmer
Local time
Tomorrow, 00:24
Joined
Sep 15, 2011
Messages
31
Hi,
I have a database that e-mails a report to users as soon as the report is created. I am using the "SendObject" method.

I need to have the e-mail automatically be send, without the user having to click on "Send". Currently, Outlook opens with the report and the e-mail addresses, but pops up with the send screen and the user has to click on "Send". I want this to happen in the background.

How can I achieve this with MS Access 2010 and VBA?

Thanks
 
Just ensure that you set the "EditMessage" parameter to False (as highlighted below in red):
Code:
DoCmd.SendObject acSendReport, "ReportName", acFormatPDF, "Email@Address.com", , , "Subject", "Message", [COLOR="Red"]False[/COLOR]
But I think you will keep getting a message box asking for permission to send the e-mail so you can use the Outlook object instead:
http://bytes.com/topic/access/answe...s-report-attachment-via-outlook-automatically
 
Thanks a mill - this resolved the issue
 

Users who are viewing this thread

Back
Top Bottom