TPBPIT
asked on
VBA code to set Sensitvity Tag to Private based on a certain recipient in the recipient lines in Outlook
I am trying to figure out if there is a way when one of my users creates an email to a certain email group, say Friends, that the new email message will automatically set the Sensitivity Tag to Private and display a message that it was set and not allow it to be changed? Or another possible approach would be that when the user tries to send the email with that group in one of the recipient lines it will check to see if Sensitivity Tag is set to Private and if not, it would pop up a message telling them to set it and not let the user send the email until that tag is set. The message would continuously pop up when the user tries to send until the tag is set.
I would imagine this can be done, but I haven't coded VBA in a long time and never for Outlook.
I would imagine this can be done, but I haven't coded VBA in a long time and never for Outlook.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Yes, sure. Like this in line 4:
If Recip.Name = "Friends" Or Recip.Name = "Enemies" Then
ASKER
Thanks for the help with this. It worked perfectly.
ASKER
And if you do Recip.Name instead, and you wanted to use group names from the global address list, who would you enter the name? Just as it reads in the GAL?