Hi,
We have a message in our Drafts folder and we want to update it. Is there any way we can update the message in the drafts folder?
Hi,
We have a message in our Drafts folder and we want to update it. Is there any way we can update the message in the drafts folder?
Hi Aaron,
//
Create instance of IEWSClient class by giving credentials<o:p></o:p>
IEWSClient client = GetAsposeEWSClientTest3();
ExchangeMailboxInfo mailboxInfo = client.GetMailboxInfo();
ExchangeFolderInfo subfolderInfo = new ExchangeFolderInfo();
client.FolderExists(mailboxInfo.RootUri, "Drafts", out subfolderInfo);
ExchangeMessageInfoCollection msgInfoColl = client.ListMessages(subfolderInfo.Uri);
foreach (ExchangeMessageInfo msgInfo in msgInfoColl)
{
MailMessage mail = client.FetchMessage(msgInfo.UniqueUri);
mail.Body = "Modified:" + mail.Body;
client.DeleteMessage(msgInfo.UniqueUri);
client.AppendMessage(subfolderInfo.Uri, mail);
}