none
EWS Managed API (2.0) RRS feed

  • Question

  • I've created a console application which synchronizes contact persons to a public folder in our Office 365 using the EWS Managed API (2.0). Problem is, that the notes of a contact aren’t always displayed correctly (using Outlook 2013 client).

    In the default ‘People view’, the notes are displayed correctly. But when the ‘List view’, in the detail screen, the notes aren’t displayed...

    I'm using the 'Body' property to set the notes.

    Any idea what could be the problem?

    Friday, December 27, 2013 2:09 PM

Answers

  • I don't believe HTML is supported in the contacts notes field, the edit control in Outlook use RTF so will set/get the PidTagRtfCompressed property. If you logon and look at the contact in OWA it only uses the plain text body so it won't show any RTF formatting applied to the Notes and if you modify the Notes in OWA you will lose any formatting that has been applied in Outlook. This isn't new in 2013 it happens in 2010 as well so It would be hard to call it a new bug.

    My suggestion would be you stick to using Text only in the Notes field. You could set the PidTagRtfCompressed with EWS but you would have to generate the content yourself.

    Cheers
    Glen


    Wednesday, January 1, 2014 8:24 AM

All replies

  • You might want to post a screenshot of what the problem is and the code your using. There is a existing bug with EWS created contacts which maybe related so I'd also maybe try the properties listed in http://social.technet.microsoft.com/Forums/exchange/en-US/90d7e749-977e-4191-87cf-725007a326b4/contacts-created-by-ews-v20-are-visible-in-outlook-but-not-in-owa-in-office-365?forum=exchangesvrdevelopment

    Cheers
    Glen

    Monday, December 30, 2013 6:01 AM
  • In 'People' view, the notes ('SOME NOTES') are displayed correctly:

    In 'List' view however, the notes aren't visible:

    Code that I'm using:

    contactToSave.Body = new MessageBody("SOME NOTES");

    I found out, that when setting the body type to 'Text', the notes are displayed in both views.

    contactToSave.Body = new MessageBody(BodyType.Text, "SOME NOTES");

    So obviously, when setting the body type to HTML or setting no body type at all, the problem as described above occurs. Also giving the same problem:

    contactToSave.Body = new MessageBody(BodyType.HTML, "<html><body>SOME NOTES</body></html>");


    Tuesday, December 31, 2013 3:03 PM
  • I don't believe HTML is supported in the contacts notes field, the edit control in Outlook use RTF so will set/get the PidTagRtfCompressed property. If you logon and look at the contact in OWA it only uses the plain text body so it won't show any RTF formatting applied to the Notes and if you modify the Notes in OWA you will lose any formatting that has been applied in Outlook. This isn't new in 2013 it happens in 2010 as well so It would be hard to call it a new bug.

    My suggestion would be you stick to using Text only in the Notes field. You could set the PidTagRtfCompressed with EWS but you would have to generate the content yourself.

    Cheers
    Glen


    Wednesday, January 1, 2014 8:24 AM
  • If you have the option to provide HTML-text as notes of a contacts (with the API), it looks weird to me if you cannot view this in a Outlook 2013 client. But as the text-notes are displayed fine and I don't need any formatting, I just stick to this body type.
    Thursday, January 2, 2014 2:16 PM
  • Hi, Glen

    I tried to use EWS managed api to update email item by adding an attachment  larger than 10M using

    item.update() 

    it take some time to update email body, but attachment updates failed  because of timeout ?

    my questions are 

    1. how to update a large attachment using EWS  Item.update() ?

    2. how to make the update as an atomic  operation (body + attachment) ?

    Thanks,

    ys

    Saturday, January 4, 2014 7:22 PM