EWS on office 365 throw error while sending mail RRS feed

  • Question

  • Hi,

    Our organization has moved to office 365 and we are facing error while sending a mail with attachment. it is working fine without the attachment.

    we have to make some changes to fetch and send mail mail send and below is the solution which we found on google for Impersonation :

    service.HttpHeaders.Add("X-AnchorMailbox", MailboxToAccess);

    even after making the changes we are getting the below error when sending mail with attachment. it work when there is no attachment in the mail.

    <Trace Tag="EwsResponse" Tid="1" Time="2019-01-21 15:10:12Z" Version="15.00.0516.014">
      <?xml version="1.0" encoding="utf-8"?>
      <s:Envelope xmlns:s="">
          <h:ServerVersionInfo MajorVersion="15" MinorVersion="20" MajorBuildNumber="1537" MinorBuildNumber="31" Version="V2018_01_08" xmlns:h="" xmlns:xsd="" xmlns:xsi="" />
          <m:CreateItemResponse xmlns:m="" xmlns:xsd="" xmlns:xsi="" xmlns:t="">
              <m:CreateItemResponseMessage ResponseClass="Error">
                <m:MessageText>The specified object was not found in the store., Can't connect to the mailbox of user Mailbox database guid: 483146e9-3363-49d3-b88e-8e04d88d33f8 because the ExchangePrincipal object contains outdated information. The mailbox may have been moved recently.</m:MessageText>
                <m:Items />

    • Edited by Ishu_Chy Monday, January 21, 2019 3:40 PM
    Monday, January 21, 2019 3:38 PM