Link to home
Start Free TrialLog in
Avatar of Martin Holmes
Martin Holmes

asked on

EWS email move stopped working

We currently use EWS to move emails from the inbox of one mailbox to the inbox on another mailbox based on specified criteria. The code is as follows:

private void MoveEmailToAttacherMailbox(string id, string attacherMailbox)
    {
      DocStore.Logger.Info(string.Format("{0} id: {1} To attacherMailbox: {2}", (object) nameof (MoveEmailToAttacherMailbox), (object) id, (object) attacherMailbox));
      try
      {
        Item.Bind(this.exchangeService, (ItemId) id).Move(new FolderId(WellKnownFolderName.Inbox, (Mailbox) attacherMailbox));
      }
      catch (Exception ex)
      {
        ProjectData.SetProjectError(ex);
        Exception exception = ex;
        DocStore.Logger.WarnException(nameof (MoveEmailToAttacherMailbox), exception);
        ProjectData.ClearProjectError();
      }

Unfortunately since 29th November we have been getting an error: "MoveEmailToAttacherMailbox Microsoft.Exchange.WebServices.Data.ServiceResponseException: The move or copy operation failed."

No permissions have changed and the mailbox we are moving from has full delegate permissions to the mailbox we are moving to. Any assistance will be greatly appreciated.
Avatar of Amit
Amit
Flag of India image

I advise you to check iis logs, look for error code for both accounts, it can help you to find the cause, you can also restart iis or server and check again. Lot of time simple restart fixes several issues.
Avatar of Martin Holmes
Martin Holmes

ASKER

Hi, we use O365 so do not have access to IIS logs. Will there be any logs anywhere in the O365 admin portal i can check?
Open case with office 365 team.
This question needs an answer!
Become an EE member today
7 DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform.
View membership options
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.