Confidential Flag

  • Thread starter Thread starter Michael Hyatt
  • Start date Start date
M

Michael Hyatt

I want a toolbar button on the New message and Reply message form that will
select the "Confidential" flag on. As you know, you can do this by selecting
View | Options | Message Settings | Sensitivity | Confidential. I found a
button for Options, but I have not been able to find one for Confidential.
(If I'm missing something, please let me know.)

Can I write a simple VBA macro and attach it to a button? What is the code
for changing the sensitvity of the current message?

Thanks.
 
Thanks.

How can I test whether or not the CurrentItem is a reply window (a message
the user is replying to verses a new message he is composing)?
 
I answered my own question. This is a bit of a kludge, but it works:

Sub ConfidentialFlag()

strSubject = Outlook.ActiveInspector.CurrentItem.Subject

If Left(strSubject, 3) = "RE:" Then ' This is a reply message
Outlook.ActiveInspector.CurrentItem.Sensitivity = olConfidential
strBody = Outlook.ActiveInspector.CurrentItem.HTMLBody
Outlook.ActiveInspector.CurrentItem.HTMLBody = _
"<FONT face=Verdana size=2 color=blue>" & _
"<STRONG>CONFIDENTIAL - DO NOT FORWARD</STRONG>" & _
"</FONT><br><br>" & strBody
SendKeys "{DOWN 4}"
Else ' This is a
new message
Outlook.ActiveInspector.CurrentItem.Sensitivity = olConfidential
strBody = Outlook.ActiveInspector.CurrentItem.HTMLBody
Outlook.ActiveInspector.CurrentItem.HTMLBody = _
"<FONT face=Verdana size=2>" & _
"<STRONG>CONFIDENTIAL - DO NOT FORWARD</STRONG>" & _
"</FONT><br><br>" & strBody
End If

End Sub
 
Back
Top