exchange-serverexchangewebservicesews-managed-apiextended-properties

How to get "Web page" contact field through Exchange EWS/EWS managed api?


I'm trying to extract contacts from exchange using EWS managed api. I've managed to find Property tags of almost all the fields through this link.

Still there are some fields I'm not able to get. The main one is the field "Web Page". Is this field available as some other name because searching for this through the list of Property tags in the above link is not matching any.

Thanks in advance for any help.


Solution

  • You need to get/set the PidTagBusinessHomePage extended property https://msdn.microsoft.com/en-us/library/cc842385(v=office.12).aspx eg

      ExtendedPropertyDefinition PR_BUSINESS_HOME_PAGE = new ExtendedPropertyDefinition(0x3A51, MapiPropertyType.String);
      Contact.SetExtendedProperty(PR_BUSINESS_HOME_PAGE,"http://blahblahlblah.com");
    

    or

            ExtendedPropertyDefinition PR_BUSINESS_HOME_PAGE = new ExtendedPropertyDefinition(0x3A51, MapiPropertyType.String);
            PropertySet psContactPropSet = new PropertySet(BasePropertySet.FirstClassProperties);
            psContactPropSet.Add(PR_BUSINESS_HOME_PAGE);
            Contact Contact = Contact.Bind(service,Id,psContactPropSet)
    

    Cheers Glen