Reputation: 17849
I'm using EWS to bind to a specific message in my mailbox on Exchange. All was going fine until I added an extended property to my request. How do I set this 'FieldURI' property? (which none of the objects involved seem to have!)
Dim expCP = New ExtendedPropertyDefinition(DefaultExtendedPropertySet.Common, "My Custom Prop Name", MapiPropertyType.String)
prpPropsToLoadUpdateMessages.Add(ItemSchema.ExtendedProperties)
prpPropsToLoadUpdateMessages.Add(expCP)
Dim itmMessage As Item = Item.Bind(ews, New ItemId(strUniqueId), prpPropsToLoadUpdateMessages)
The 4th line of this snippet throws the error. I haven't included the code I used to define prpPropsToLoadUpdateMessages
because it's about 100 lines of adding almost every property in ItemSchema
.
TIA, Dave
Upvotes: 1
Views: 4936
Reputation: 17849
I found the solution at http://social.technet.microsoft.com/Forums/en/exchangesvrdevelopment/thread/207be791-0ae7-4fd1-b9a8-90e83249b9f8.
The problem was I was using DefaultExtendedPropertySet.Common
when it should have been DefaultExtendedPropertySet.PublicStrings
Upvotes: 1