Hello,
I have coded a button on my form to send an email to people I designate. The body of the email will come from a field entitled "Comments". How can I keep the formatting from the Comments field (hard returns, bullets, etc.) when I compose the email. Currently it puts the text in the email fine, but it's just one large paragraph with no formatting.
Here is the code I'm using right now:
Private Sub cmd_email_CRM_Click()
Dim Msg As String
Msg = "Dear " & CRM & ",<P>" & _
Please review the notes below." & "<P>" & Comments
Dim O As Outlook.Application
Dim M As Outlook.MailItem
Set O = New Outlook.Application
Set M = O.CreateItem(olMailItem)
With M
.BodyFormat = olFormatHTML
.HTMLBody = Msg
.Subject = Test
.SentOnBehalfOfName = "xyz@abc.com"
.Display
End With
Set M = Nothing
Set O = Nothing
End Sub