We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Messages retrieved from EWS that are drafts appear as "sent" once converted to MapiMessage (4.8.0)

Hi there,

When using the Aspose library to fetch items from some Exchange mailbox, then converting
MailMessage to MapiMessage and then save MapiMessage to disk, the messages that
were drafts in EWS (i.e. unsent) originally now show as “sent”.

Thank you.

Hi Sevag,

I have investigated this issue with a 3rd party API as well and the behavior is the same i.e. the downloaded messages from Drafts folder are saved as “sent”. You may consider setting these in Draft mode before saving to disc as shown in the following sample code:

Sample Code:

MailMessage eml = client.FetchMessage(coll[0].UniqueUri);

eml.Headers.Add(“X-Unsent”, “1”);

MapiMessage mapi = MapiMessage.FromMailMessage(eml);


Thank you for your response.

I can gladly set the header on messages that are drafts before saving them as this would solve my problem. However, can you tell me though how I can detect that they are draft messages once they are fetched from EWS? Not all drafts in a mailbox are going to simply be in the “Drafts” folder.

Hi Sevag,

I have logged your requirement as NETWORKNET-34590 in our issue tracking system so as to get development team’s feedback in this regard. We’ll update you here once there is some information available in this regard.

The issues you have found earlier (filed as NETWORKNET-34590) have been fixed in this update.

This message was posted using Notification2Forum from Downloads module by Aspose Notifier.