c# - How to use Microsoft.Office.Interop.Word when Windows Authentication is Enabled? -


i using microsoft.office.interop.word opening word document c# in asp.net web application , replacing of bookmarks programmatically. use windows authentication auto login. works fine when running visual studio. but, after publishing it, access denied error while application try open word document. here error get.

retrieving com class factory component clsid {000209ff-0000-0000-c000-000000000046} failed due following error: 80070005 access denied. (exception hresult: 0x80070005 (e_accessdenied))

i tried solutions posted on internet (changing permissions word in dcomcnfg, granting read/write full control folder,etc. there other solution since use windows authentication ? or going wrong ?please help.

thanks in advance

the possible workaround modify project's platform 'any cpu' 'x86' (in project's properties, build/platform's target)

mostly root cause of issue because vss interop managed assembly using 32-bit framework , dll contains 32-bit com object. if run com dll in 64 bit environment, error message.

source :- https://forums.asp.net/t/1119052.aspx?retrieving+com+class+factory+failed+due+to+the+following+error+80040154


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -