Warm tip: This article is reproduced from stackoverflow.com, please click
office-js outlook outlook-web-addins outlook-2016

How to get the values of column fields in Outlook with office.js?

发布于 2020-04-11 22:18:13

In Outlook, users can add built-in (email size, importance, etc.) or custom columns that will appear in their inbox view. (https://support.office.com/en-us/article/add-or-remove-columns-in-the-inbox-78098e3e-8203-47da-815e-cb66f76b512e)

How can I read their values? For example, how can I get the email size? Or how can get the value of a custom column?

I've read the all documentation reference of Outlook Javascript API, but I couldn't find anything.

Categories and CustomProperties are not what I am looking for.

I hope somebody can help me ????‍♂️

Questioner
Jérôme Pott
Viewed
37
Outlook Add-ins Team - MSFT 2020-02-04 21:39

These properties are not directly available through add-in APIs. You can use the makeEwsRequestAsync API to make a call to the Exchange backend, and use the GetItem EWS Operation to get properties of the message. Modify the ItemShape element to specify the properties you need.

Note that your add-in must specify the ReadWriteMailbox permission in its add-in manifest.