NetOfficeFw / NetOffice

🌌 Create add-ins and automation code for Microsoft Office applications.
MIT License
697 stars 143 forks source link

Access sensitivity label (MIP) on .msg file #324

Open mscc-sascha opened 3 years ago

mscc-sascha commented 3 years ago

Hi!

I'm currently developing an Add-In for Outlook with using NetOffice. The Add-In sends the content of a composed E-Mail to an external web service. This should be prevented whenever there are certain labels (MIP - Microsoft Information Protection) assigned (e.g. highly confidential).

In Word, Excel and PowerPoint I can read the MIP-Label by accessing CustomDocumentProperties (NetOffice.WordAPI.Document.CustomDocumentProperties). For Outlook (MailItem) ther are no such properties available, neither in any other property I can find the information.

Using the MIP-SDK is not an option because of the overhead of configuration (App Registration).

Does anyone know how to access the MIP-Label on a MailItem (or NetOffice.OutlookApi.Inspector)?

Thanks in advance!