Windows Service下调用Outlook组件出现错误:
Retrieving the COM class factory for component with CLSID {0006F03A-0000-0000-C000-000000000046} failed due to the following error: 80080005
解决方案:
打开注册表regedit并定位到HKEY_LOCAL_MACHINE\SOFTWARE\Classes\CLSID\{0006F03A-0000-0000-C000-000000000046}找到AppId的值{00020D09-0000-0000-C000-000000000046}
打开组件服务dcomcnfg
在组件服务中根据第一步获得的AppID修改运行应用程序的用户账户为交互式用户