Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/api/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
EWS托管API:会话不是复制项上的IMailboxSession_Api_Exception_Copy_Exchange Server_Exchangewebservices - Fatal编程技术网

EWS托管API:会话不是复制项上的IMailboxSession

EWS托管API:会话不是复制项上的IMailboxSession,api,exception,copy,exchange-server,exchangewebservices,Api,Exception,Copy,Exchange Server,Exchangewebservices,我们正在使用EWS管理的API处理exchange公用文件夹中的项目。我们能够遍历文件夹,检索新项目并更改它们。可以将项目移动到特定文件夹,但当我们使用复制方法时,会发生奇怪的异常:发生内部服务器错误。操作失败。IdAndSession.MailboxSession:会话不是IMailboxSession 要排除代码问题,我使用microsoft提供的示例: // As a best practice, limit the properties returned by the Bind meth

我们正在使用EWS管理的API处理exchange公用文件夹中的项目。我们能够遍历文件夹,检索新项目并更改它们。可以将项目移动到特定文件夹,但当我们使用复制方法时,会发生奇怪的异常:发生内部服务器错误。操作失败。IdAndSession.MailboxSession:会话不是IMailboxSession

要排除代码问题,我使用microsoft提供的示例:

// As a best practice, limit the properties returned by the Bind method to only those that are required.
PropertySet propSet = new PropertySet(BasePropertySet.IdOnly, EmailMessageSchema.Subject, EmailMessageSchema.ParentFolderId);
// Bind to the existing item by using the ItemId.
// This method call results in a GetItem call to EWS.
EmailMessage originalMessage = EmailMessage.Bind(service, ItemId, propSet);
// Copy the orignal message into another folder in the mailbox and store the returned item.
Item item = originalMessage.Copy("epQ/3AAA=");
// Check that the item was copied by binding to the copied email message 
// and retrieving the new ParentFolderId.
// This method call results in a GetItem call to EWS.
EmailMessage copiedMessage = EmailMessage.Bind(service, item.Id, propSet);
但例外情况仍然存在。这可能是框架中的一个bug吗? 提前感谢您的帮助