Quantcast
Channel: Aspose.Email Product Family
Viewing all articles
Browse latest Browse all 1367

Exchange 2003 WebDav MoveItem failed

$
0
0

Hi,

I have a folder named "Not Correct" In my mailbox.

When I use aspose to move item from my inbox to  this folder I have an exception.

Codes:

ExchangeClient client = new ExchangeClient("http://..../exchange/userName",MyNetworkCredential);
ExchangeFolderInfo fInfo;
if (client.FolderExists(client.MailboxInfo.RootUri, "Not Correct", out fInfo))
{
     strFolderUri = fInfo.Uri;
}

foreach (ExchangeMessageInfo msgInfo in client.ListMessages("http://..../exchange/userName/Inbox",
                    100,
                    ExchangeListMessagesOptions.None))
{  
client.MoveItem(msgInfo.UniqueUri,strFolderUri + Guid.NewGuid().ToString() + ".eml")
}

WorkAround:

Replace client.MoveItem(msgInfo.UniqueUri,strFolderUri + Guid.NewGuid().ToString() + ".eml")
with client.MoveItem(msgInfo.UniqueUri, Uri.UnescapeDataString(strFolderUri) + Guid.NewGuid().ToString() + ".eml")


Viewing all articles
Browse latest Browse all 1367

Trending Articles