line breaks using doCmd.SendObject

jonnycattt

Registered User.
Local time
Today, 20:44
Joined
Sep 29, 2001
Messages
20
Hi all,
I've got a button that calls doCmd.SendObject when clicked. In the resulting email that pops up, I need to insert some line breaks. How do I do that?

Here's the offending code:

DoCmd.SendObject acSendQuery, "qry_Jnut_Report", acFormatXLS, "XXX@ajn.org", , , "JNUT Report", "Dear So and So, Attached is this month's XXX Report. Kevin", True

So what I want is to separate the subject from the greeting and salutation.

I appreciate any advice.

Marc
 
strMsg = "Dear So and So," & vbNewLine & "Attached is this month's XXX Report." & vbNewLine & "Kevin"
DoCmd.SendObject acSendQuery, "qry_Jnut_Report", acFormatXLS, "XXX@ajn.org", , , "JNUT Report", strMsg, True
 
Excellent. Thanks!
 

Users who are viewing this thread

Back
Top Bottom