开发者

EWS error when updating an item Category

I get the following error when calling the Update() method on an Item in my VB .Net application using EWS (logged on to Exchange 2007 SP1):

Property update did not succeed

What could be the cause?

I'm really hoping this is not due to EWS requiring Exchange 2010 to update cat开发者_开发问答egories on an item. The only update I made to the item was to Add a category.

EDIT:

Also, the following code, which makes a copy of the message and updates its category works fine. So it looks like it's only changing the category property for existing messages that's the problem.

Dim itmMessage2 = itmMessage.Copy(itmMessage.ParentFolderId)
itmMessage2.Categories.Add(strCategoryName)
itmMessage2.Update(ConflictResolutionMode.AlwaysOverwrite)

Cheers, Dave


I have no idea why this solution worked, but it makes me think something was slightly broken with either my API installation, or on the Exchange 2007 SP 1 server I'm connecting to:

I sent through a bind() request asking for every ItemSchema property that Exchange 2007 supports (so not UniqueBody etc. which is 2010 specific).

Now my original code is working fine.

And it stays working just fine even after I remove all the property requests!

Go figure. :|


I've faced a similar "Property update did not succeed" problem when tried to update the Category with a string containing a comma.

Removing comma character solved my problem.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜