Hi,
I am trying to add a 'Confidential' sensitivity label to the below code with no luck.
I have tried adding ".Sensitivity = 3" as shown below but it does not change the label.
Can anyone help me with this please?
Thanks.
I am trying to add a 'Confidential' sensitivity label to the below code with no luck.
I have tried adding ".Sensitivity = 3" as shown below but it does not change the label.
Can anyone help me with this please?
Thanks.
VBA Code:
Sub EmailTest()
Dim OutApp As Object
Dim OutMail As Object
Dim strbody As String
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(0)
strbody = "<html><body>"
strbody = strbody & "Hi,"
strbody = strbody & "<p><B>Add body of email here."
strbody = strbody & "</body></html>"
On Error Resume Next
With OutMail
.Display
.To = Range("ToRange").Text
.CC = Range("CCRange")Text
.BCC = ""
.Subject = "Test Email Subject - " & Format(Now(), "DD/MM/YY")
.HTMLBody = strbody & "<br>" & .HTMLBody
.Sensitivity = 3
.Display
End With
On Error GoTo 0
Set OutMail = Nothing
Set OutApp = Nothing
End Sub