Using Exchange Server 2010 and progrmming VB.net.
I am trying to get values from an exchange search through EWS. I have managed to get values from my extended userproperties in Outlook contacts with this:
- Dim USER_iban As New ExtendedPropertyDefinition(DefaultExtendedPropertySet.PublicStrings, "iban", MapiPropertyType.String)
- view.PropertySet = New PropertySet(BasePropertySet.FirstClassProperties, New PropertyDefinitionBase() {USER_cprnr, USER_Type, USER_BS})
- Dim foundItems As FindItemsResults(Of Item) = service.FindItems(correctfolder.Id, searchFilter, view)
Works just great. But I am unable retrieve values from fields not in the set of firstclassproperties - like ContactSchema.Birtday.
I have tried with
- view.PropertySet = New PropertySet(BasePropertySet.FirstClassProperties, New PropertyDefinitionBase() {USER_cprnr, USER_Type, USER_BS, ContactSchema.Birthday})
or
- view.PropertySet.Add(ContactSchema.Birthday)
but all the time I get this kind of error: {"This property was requested, but it wasn't returned by the server."}
Are you able to point me in a direction to find a solution?
- Allan