I'm attempting to leverage the Microsoft.Office.Interop.Word dll in my asp.net application. Long story short, an internal web based document management/editing system requires access to a MS Word flesch-kincaid value on an ad-hoc basis. I have no problem using this dll in a console app, but I can't get the right permissions to it when accessed via asp.net.
Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following error: 80070005 Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)).
I've tried everything in this forum thread with no luck. I'm using .Net 4.0 on Win7, I've tried both 32 and 64 bit versions of MS Word. I'm also anticipating more head-aches once I deploy to our server running Windows Server 2008 R2 Standard
I would use the openXML SDK instead for the reason todda.speot.is gives
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=5124
http://www.codeproject.com/Articles/87711/Manipulate-Docx-with-C-without-Microsoft-Word-inst
来源:https://stackoverflow.com/questions/9438577/using-microsoft-office-interop-word-in-asp-net