The outlook add-in contains a textbox where a user can enter any information. I want to store this information and retrieve it every time the user uses the add-in. As in, the information entered by the user must be retained for the following times they use the add-in.
I tried to get custom properties using EWS or REST, but I am not aware of how to utilize this or if this approach is the correct one.
It is not clear from your description whether a text box control will be used for displaying data per mailbox or specific item in Outlook. Depending on that you may choose the best place for keeping your custom data. You can manage custom data in your Outlook add-in by using either of the following:
Roaming settings
- which manage custom data for a user's mailbox.Custom properties
- which manage custom data for an item in a user's mailbox.Both of these give access to custom data that's only accessible by your Outlook add-in, but each method stores the data separately from the other. That is, the data stored through roaming settings
isn't accessible by custom properties
, and vice versa. Roaming settings
are stored on the user's mailbox while custom properties
are stored on a message or appointment. Stored data is accessible in subsequent Outlook sessions on all the form factors that the add-in supports. Read more about that in the Get and set add-in metadata for an Outlook add-in article.