如何在 C# 中的 Outlook 中为电子邮件设置 Azure 信息保护标签之一? [英] How I can set one of Azure information Protection Labels for email in Outlook in C#?

查看:128
本文介绍了如何在 C# 中的 Outlook 中为电子邮件设置 Azure 信息保护标签之一?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Outlook 中有两个来自服务器机密"和仅限机密查看"的 Azure 信息保护标签.我需要检查电子邮件收件人的权限,如果未选择 Azure 标签,则将权限设置为 Azure 标签之一.我如何在 C# 中做到这一点?

I have two Azure Information Protection Labels in Outlook from the server "Confidential" and "Confidential View only". I need to check permission for recipients of email and if Azure labels not chosen, then set permission one of Azure Label. How I can do it in C#?

推荐答案

我有这个问题的解决方案.每个 Azure 信息保护标签都有一个 GUID,您可以从 Azure 服务器管理员处获取;

I have a solution for this issue. Every Azure Information Protection Label has a GUID, you can get from Azure server Administrator;

如果需要为MailItem设置权限就试试这个

If need to set permission for MailItem just try this

MailItem item = Item as Outlook.MailItem;
string templateGUID = "{5F56C571-D3E0-4A06-8896-XXXXXXXXXXXX}";
item.PermissionTemplateGuid = templateGUID;

这篇关于如何在 C# 中的 Outlook 中为电子邮件设置 Azure 信息保护标签之一?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆