|
|
Posted on 12/18/2015 2:41:18 PM
|
|
|

The function of dynamically generating Word documents in C# is realized, which is good when running on the local machine, but the error message is reported when the program is released and installed on the remote server, and the error message is:Retrieving a component with CLSID {000209FF-0000-0000-C000-00000000046} in a COM class factory fails due to the following error: 80070005This made me very entangled, and after reading a lot of information, I can only say that I have done it now. In order not to forget, I deliberately made a record of it! Method 1 (recommend): Retrieving components with CLSID {000209FF-0000-0000-C000-00000000046} in a COM class factory fails due to the following error: 8000401a 1. Run dcomcnfg.exe open Component Service, 2. Expand Component Service > Computer - > My Computer - > DCOM Configuration - > Microsoft Word Document 3. Right-click to open"Properties"Dialog box, click"LogoTab, selectThe following users, fill in the administrator's user and password correctly... 4. Click on the "Security" tab and then select "Start and activate permissions","Access rights","Configure permissions", all selected asCustomization, then click Edit on them to put the everyoneAdd it and add all permissions 5. Please set the <identity impersonate="true" userName="Administrator" password="abc123"/> account and password in the web.config, otherwise it will prompt to retrieve the CLSID in the COM class factory as {000209FF-0000-0000-C000-000000000046 component fails due to the following error: 80070005. For example<system.web><identity impersonate="true" userName="Administrator" password="abc123"/></system.web>
Method 2:
1. Control Panel - "Management Tools" - "Component Services" - "Computer" - "My Computer" - "DCom Configuration" after locating the Microsoft Word document 2. Right-click "Properties" to open the properties dialog box of this application. 3. Click on the Security tab and click on theStart and activate permissions"And"Access rightsSelected in GroupCustomizationThen Custom->Edit->Add ASP.NET accounts and IUSER_ computer names or Network Service users * These accounts only exist if IIS is installed on the computer. Make sure to allow access for each user, then click OK. 4. Click OK to close DCOMCNFG
|
Previous:How about Huawei Water Cube, ready to buy one?Next:A potentially dangerous Request.Form value was detected
|