J
joave
Hi:
I am attempting to insert specific text into the body of an HTML message
using Word as the editor with VBA. However, when I change the body of the
message, my signature disappears. Can someone please tell me how to keep the
signature in the message while inserting additional text? I have tried
several different methods but none seem to work.
Here is my current code (with some failed attempts at the above goal):
Dim objOLApp As Outlook.Application
Dim NewMail As Outlook.MailItem
Set objOLApp = New Outlook.Application
Set NewMail = objOLApp.CreateItem(olMailItem)
NewMail.Display
NewMail.To = "CF Reports"
NewMail.Subject = "Report " & Date - 1
Dim Temp As String
Temp = "Hi Team, </br>" & vbCrLf & vbCrLf & " Here is the latest Report.
Please let me know if you have any questions." & vbCrLf & vbCrLf & "Thank
you,"
Temp = Temp & vbCrLf & vbCrLf & "David " & NewMail.HTMLBody
NewMail.HTMLBody = Temp
'NewMail.Body = Temp
Thank you in advance,
Dave
I am attempting to insert specific text into the body of an HTML message
using Word as the editor with VBA. However, when I change the body of the
message, my signature disappears. Can someone please tell me how to keep the
signature in the message while inserting additional text? I have tried
several different methods but none seem to work.
Here is my current code (with some failed attempts at the above goal):
Dim objOLApp As Outlook.Application
Dim NewMail As Outlook.MailItem
Set objOLApp = New Outlook.Application
Set NewMail = objOLApp.CreateItem(olMailItem)
NewMail.Display
NewMail.To = "CF Reports"
NewMail.Subject = "Report " & Date - 1
Dim Temp As String
Temp = "Hi Team, </br>" & vbCrLf & vbCrLf & " Here is the latest Report.
Please let me know if you have any questions." & vbCrLf & vbCrLf & "Thank
you,"
Temp = Temp & vbCrLf & vbCrLf & "David " & NewMail.HTMLBody
NewMail.HTMLBody = Temp
'NewMail.Body = Temp
Thank you in advance,
Dave