获取 contact.LastName 时出现 System.Runtime.InteropServices.COMException (0x800706BE)
我们的一些用户有时会遇到此异常(并非每个联系人):
System.Runtime.InteropServices.COMException (0x800706BE):
The remote procedure call failed. (Exception from HRESULT: 0x800706BE)
at Microsoft.Office.Interop.Outlook._ContactItem.get_LastName()
当我们尝试获取联系人(ContactItem
类型)的姓氏时,就会发生这种情况。
有人知道问题是什么吗?
任何帮助将不胜感激。谢谢!
Some of our users are getting this exception sometimes (not for every contact):
System.Runtime.InteropServices.COMException (0x800706BE):
The remote procedure call failed. (Exception from HRESULT: 0x800706BE)
at Microsoft.Office.Interop.Outlook._ContactItem.get_LastName()
This happens when we're trying to get the last name of a contact (of the ContactItem
type).
Does anybody know what the problem is?
Any help would be appreciated. Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这是一个 Windows 错误,设施代码 7。最后一个字给出了 Windows 错误,0x6be == 1726:
与 Outlook 等 Office 程序的互操作通过进程外 COM 发生。 RPC 是低级远程过程调用机制。这种远程调用失败的原因有多种。错误代码和错误名称谷歌一下都很好。
最简单的解释就是 Outlook 崩溃了。就会发生这种情况。进程内互操作的优点是,当主机程序崩溃时,它也会删除您的代码。不是在进程外场景中,您只会遇到难以诊断的错误。要求客户的 IT 员工使用他们典型的 Office 故障排除策略。
It is a Windows error, facility code 7. The last word gives the Windows error, 0x6be == 1726:
Interop with Office programs like Outlook happens through out-of-process COM. RPC is the low-level Remote Procedure Call mechanism. There are several reasons for such a remote call to fail. Both the error code and the error name google well.
The simplest explanation is just that Outlook fell over. That happens. The advantage of in-process interop is that when the host program crashes then it will take out your code as well. Not in an out-of-process scenario, you just get a hard to diagnose error. Ask your customer's IT staff to use their typical Office troubleshooting strategies.
将网络服务(或应用程序池的标识)的完全访问权限设置为文件夹 C:\Windows\System32\config\systemprofile\AppData
问候!
加布里埃尔(来自阿根廷)
set the full access to Network Services (or identity of apppool) to the folder C:\Windows\System32\config\systemprofile\AppData
Regards!
Gabriel from Argentina