Failed to retrieve components whose CLSID is {00024500-0000-0000-c000-000000000046} in COM class factory

Source: Internet
Author: User
Tags microsoft access database

Http://blog.csdn.net/wzhibin/article/details/1816690

Use. net writes a B/S program related to excel and deploys it on the server of the 2003 Enterprise Edition. This error occurs: retrieving components whose CLSID is {00024500-0000-0000-c000-000000000046} in the com class factory fails, the cause is the following error: 80070005. Search for the solution on the Internet and paste it to your notes. Http://www.cnblogs.com/piedpiper/articles/627764.htmlthen it is normal. I did not expect that after two days, a sudden error occurs again. Check permissions. No problem. It's just a faint. A friend on the Internet suggested installing the SP1 Patch. But I have already installed patches. Final Solution: Close Excel and VBA based on Limit + F11; 2. click Start, click run, and then type dcomcnfg; 3. click "component service"> "computer"> "my computer"> "DCOM configuration". A dialog box is displayed, indicating "register. In this case, everything is back to normal and you do not need to perform any further operations. The kernel of Microsoft's office is too old and has many problems.

 

The solution is as follows:

1: Install the Excel software for office on the server.

2: Enter dcomcnfg.exe in "start"-> "run" to start "Component Service"

3: Double-click "component service"> "computer"> "my computer"> "DCOM configuration"

4: Find "Microsoft Excel application" in "DCOM configuration", right-click it, and then click "properties ".

Application Properties dialog box

5. Click the "ID" tab and select "Interactive User"

6. Click the "Security" tab, click "Custom" on "Start and activate Permissions", and then click the corresponding "edit" button. In the displayed "security" dialog box, enter

A "Network Service" user (note that you must select the computer name), and grant it the "local start" and "Local activation" permissions.

7: the "Security" label is still displayed. Click "Custom" on "Access Permissions", and then click "edit". In the displayed "security" dialog box, add a "network"

Service, and then grant the "local access" permission.

In this way, we have configured the corresponding Excel DCOM permissions.

Note: This is configured on win2003. On 2000, it may be the configuration of ASPNET users.

Because Excel is opened on the server, you should write a method to save the exported data on the server and pass it to the client.

Use this function to delete all Excel files generated on the server.

An error occurred while creating an Excel application:

Failed to retrieve components whose CLSID is {00024500-0000-0000-c000-000000000046} in the com class factory because of the following error: 80070005

Solution: configure the Excel application in DCOM:

To set up an Office Automation server under an interactive user account, follow these steps:

1. Log on to your computer as an administrator and use the full installation method to install (or reinstall) The office. To ensure system reliability, we recommend that you copy the content from the office CD-ROM to your local drive and install office from this location.
2. Start the Office application that you want to run automatically. This forces the application to register itself.
3. After running the application, press Alt + F11 to load the Microsoft Visual Basic for Applications (VBA) Editor. This forces VBA to initialize.
4. Close the application, including VBA.
5. ClickStart, ClickRunAnd then type dcomcnfg. Select the application to run automatically. The Application name is as follows: Microsoft Access 97-Microsoft Access database
Microsoft Access 2000/2002-Microsoft Access Application
Microsoft Excel 97/2000/2002-Microsoft Excel application
Microsoft Word 97-Microsoft Word basic
Microsoft Word 2000/2002-Microsoft Word document clickAttributeOpen the Properties dialog box for this application.

6. ClickSecurityTab. VerifyUse the default access permissionAndUse the default start permissionSelected.
7. ClickIdentifierTab, and then selectInteractive User.
8. ClickOKTo close the Properties dialog box and return to the main Application List dialog box.
9. InDCOM ConfigurationIn the dialog box, clickDefault SecurityTab.
10. ClickEdit Default Value. Verify that the following users are listed in the access permission. If not, add these users: System
Interactive
Everyone
Administrators
IUSR _ <machinename>*
IWAM _ <machinename>*

*These accounts only exist when Internet Information Server (IIS) is installed on the computer.
11. Make sure that each user is allowed to access, and then clickOK.
12. ClickEdit Default Value. Verify that the following users are listed in the startup permission. If not, add these users: System
Interactive
Everyone
Administrators
IUSR _ <machinename>*
IWAM _ <machinename>*

*These accounts only exist when IIS is installed on the computer.
13. Make sure that each user is allowed to access, and then clickOK.
14. ClickOKDisable dcomcnfg.

Failed to retrieve components whose CLSID is {00024500-0000-0000-c000-000000000046} in COM class factory

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.