iis 7 - How to deploy COM object Microsoft.Office.Interop to IIS so that my C# WCF service reference will work? -
I am getting an error while trying to run my web application from IIS 7 on my local machine. Outlook is like the following ...
Failed to retrieve a COM class factory for component with CLSID {0006F03A-0000-0000-C000-000000000046} due to the following error: 80070005 Access denied is. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))
When I run this same web app from VS2010 and Cassini, then I have no problem.
When I run the web app from IIS 7, I indicate my VS2010 on the IIS virtual directory. In fact I was also making the VS 2010 Virtual Directory. So I'm debugging with VS-2010 and I have gathered the error posted here.
I went to Microsoft. Office. Inter.Outok.AL To read, write, modify and delete files and everyone. Just to exclude safety.
What are the other ways when Microsoft.Office.Interop refers to DLL? I should configure something different about this, then switch back to running in Cassini and there is no problem.
SharePoint is installed on my server and it is running under the account "Network Service" This is a hidden Which will not normally be allowed to run COM objects if you go to IIS and see which app pool is using it (under advanced settings) then check the identity of that pool. A friend recommended that we run our SharePoint app pool (and other services) under a designated account (such as [domain] \ svcSharepoint) so that you can explicitly allow. Otherwise, the network service account [domain] will appear in the form of [machine name] $ (last $ note, which means "hidden account").
Another factor would be if you installed it on Server 2008 R2, because the UAC stuff is quite strong and will surely refuse such interaction. Closing the UAC is a little risky, but it can be a winner.
The last factor will check the DCOM configs for that COM object. [Start Menu, Administrator Tools] [Component Services] [DCOM Config] By Name Or Lookup Outlook By GUID, Proper, Security
Comments
Post a Comment