I am trying to send outlook mail using VBA . Every time I run my macro a pop-up comes to me of TITUS stating as select data risk classification. My question is if there any way I can bypass it or select it automatically and send an email.
I have the attempted code snippets to achieve it from multiple sources from internet below.
Sub test()
Dim AOMSOutlook As Object
Dim AOMailMsg As Object
Set AOMSOutlook = CreateObject("Outlook.Application")
Dim objUserProperty As Object
Set AOMailMsg = AOMSOutlook.CreateItem(0)
Set objUserProperty = AOMailMsg.UserProperties.Add("TITUSAutomatedClassification", 1)
objUserProperty.Value = "TLPropertyRoot=ABCDE;Classification=Internal;Registered to:My Companies;"
With AOMailMsg
.To = "[email protected]"
.Subject = "New Report"
.HTMLBody = "Hi"
.Save
.Send
End With
Set AOMailMsg = Nothing
Set objUserProperty = Nothing
Set AOMSOutlook = Nothing
Set lOMailMsg = Nothing
Set objUserProperty = Nothing
Set lOMSOutlook = Nothing
End Sub
Also please clear if objUserProperty.Value = "TLPropertyRoot=ABCDE;Classification=Internal;Registered to:My Companies;
Registered to: (has to be actual company name)
Thanks in advance.
CodePudding user response:
You may contact Titus developers for the actual format of the string that needs to be set to avoid any popups from their add-in in Outlook. Also you may check out the sent items for properties set by the add-in, use any low-level property explorer tool such as MFCMAPI or OutlookSpy
for that.