Chris Crowe's Blog
Ramblings of an IIS MVP ( MVP Since 1997 )

Powered By IIS 7

Search my blog

Some of my readers



My Microsoft Certifications


Dec 15, 1998

Dec 20, 2000

Jan 31, 2001

Jul 22, 2002

Nov 1, 2004

My Microsoft MVP Awards




1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
mvp.support.microsoft.com

If you add a reference to Microsoft Excel and then try to use it within your ASP.NET application you may receive the following error.

Server Error in '/excel' Application.


Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80070005.

Example Application

The problem is that by default Microsoft Excel as a COM object can only activated by the following accounts:

  • Administrator
  • System
  • Interactive

When you are running your ASP.Net account on Windows XP your web application is running as the ASPNET account.

The way to resolve this issue is to edit the DCOM configuration settings for the Microsoft Excel Application object.

Configure DCOM

  • Go to the Start-Run menu item.
  • Type in "DCOMCNFG" and hit enter.
  • This should load the "Component Services" MMC (you can also load from Administrative Tools - Component Services"
  • Expand "Component Services"
  • Expand "Computers"
  • Expand "My Computer"
  • Select the "DCOM Config" item
  • Select the "Microsoft Excel Application" item.
  • Right click and select Properties
  • Select the Security Tab and you should see the following:



     
  • Under "Launch and Activation Permissions" select the "Customize" option.
  • Click the "Edit" button

    Windows XP

             

    Windows 2003 Server

     

      
     
  • Click the "Add" button to add a new account to the list.
  • On the dialog that is displayed click the Locations button

    (this is because by default your domain will be selected and we need a local account)

    In this dialog scroll the list to the top (sometimes the first item is not visible) but scroll to the top and select the first item which is your computer name. In the list below "CCROWE" is the name of my computer.



     
  • Click the OK button
  • On the dialog that is displayed enter "ASPNET" as the account name (make sure location is set to the name of the computer that IIS is on) on Windows XP or if you are running on Windows 2003 Server you must enter the account that the Application Pool is running as, by default "Network Service"

    Windows XP

                  

    Windows 2003 Server

    Note: A quicker way on Windows XP is to just enter the computer name and the account
    so in my case that would be:

              ccrowe\ASPNET 

     


  • Click the OK button
  • Now make sure you select the following options for the "ASP.NET Machine Account" or the account that is the application pool identity ( by default Network Service)
     
    • Local Launch         : Allow
    • Remote Launch        : [blank]
    • Local Activation     : Allow
    • Remote Activation    : [blank]

    These settings can be seen below:

  •  

    Windows XP

             

    Windows 2003 Server

     
  • Click the OK button and test your web application again and it should work fine.

Note: Remember if you are running on Windows 2003 Server you must use the application pool identity as the account and not the ASPNET account.

 

posted on Thursday, March 02, 2006 4:18 AM | Filed Under [ ASP.Net c# IIS ]

Comments


# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks for the detailed walk through!
Posted by Chris on 4/20/2007 1:04 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
After changing the configuration, do I need to reset IIS or reset the server? I'm still getting the same error.
Posted by Chris on 4/20/2007 1:32 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed

Gravatar
Are you running this on Windows XP? or maybe 2003 Server?

On 2003 Server the application pool identity would need to be used instead of the ASPNET account.

From memory it should just work without a restart of IIS or the Server.
Posted by Chris Crowe on 4/20/2007 7:59 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error

Gravatar
I have updated the article for 2003 server. Note I do not currently have a 2003 server to test the changes but I do not see why it will not work.
Posted by Chris Crowe on 4/21/2007 11:12 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thank you much for explanation how to solve the error. I had same error on XP Pro machine with MS Excell 2003.
But my web-app uses <identity impersonate="true"/> setting and I had to grant the permissions mentioned in the article to <machine_name>\IUSR_<machine_name> account. Granting the permissions to ASPNET account didn't work.
Posted by Vladimir Volynkin on 5/1/2007 1:46 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Thanks a huge lot!
I could have been banging my head on this issue for days if I hadn't found this post.
Piero
Posted by Piero Fraviga on 6/12/2007 5:00 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks for the detailed walk through... i was in a real mess before finding this..
Posted by Sriram on 6/27/2007 4:56 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks very much for yr detail help, i fixed my bugs.
Posted by John nguyen on 7/3/2007 3:48 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Hi i have the problem on a windows xp, and on a windows 2003 server. In the windows 2003 server i could fix the problem. But in my desktop (windows xp) i don't see the microsoft excel application component. I don't know why, i have installed the microsoft office 2000 sp3
Posted by Juan Cruz on 7/5/2007 5:56 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Hi,
I have a similar problem, I have developed a VB.NET console application which uses a Visual Basic 6.0 Richtextbox class to convert data from plain text to rich text and vice-versa.

The application is working fine on my box(windows xp professional service pack 2) and couple of other development boxes, but when I tried to install it on couple of other servers I get an error at the place where the code accesses this VB 6.0 Richtext box class.

"Retrieving the COM class factory for component with CLSID {3B7C8860-D78F-101B-B9B5-04021C009402} failed due to the following error: 80040154."


Can you pl look into this error and let me know if I am missing something..


Thanks
Ravi Nallavelli
Posted by Ravi on 7/12/2007 2:49 AM

# re: COM class factory for component with CLSID

Gravatar
I am not sure if I am on the right track but this forum posts talks about some security settings for the Rich Text Control.

Problems occur when you use the Rich TextBox Control 6.0 in Office XP and in Office 2003

http://support.microsoft.com/default.aspx?scid=kb;en-us;838010

This problem occurs because Microsoft Internet Explorer adds security settings that block the Rich TextBox Control 6.0 from running. Recent versions of the Microsoft Forms 2.0 Library (FM20.dll) that are used by VBA validate the security settings of a control. Recent versions of FM20.dll determine if it is safe to initialize the object on creation by using the IObjectSafety interface. Additionally, FM20.dll checks the Internet Explorer ActiveX Compatibility policy settings to determine if a control has been marked "always unsafe".

The Rich TextBox Control 6.0 that is included with Microsoft Visual Basic 6.0 is mistakenly marked "safe for initialization." This setting implies that the Rich TextBox Control 6.0 can load persisted data from a malicious source and not endanger the user. However, the Rich TextBox Control 6.0 is merely a wrapper for the system RichEdit control (RIched20.dll). The Rich TextBox Control 6.0 does not make sure that the data that is passed to the RichEdit control is safe. Additionally, the Rich TextBox Control 6.0 does not make sure that the version of the RichEdit control that the Rich TextBox Control 6.0 uses can handle untrusted data. The Rich TextBox Control 6.0 is not supposed to be marked safe for untrusted initialization. Therefore, as a precaution, Internet Explorer 6.0 has set the "always unsafe" flag for the Rich TextBox Control 6.0. The "always unsafe" flag prevents the use of the Rich TextBox Control 6.0 in Internet Explorer 6.0, in Office XP, and in Office 2003

RESOLUTION

If you design solutions for Microsoft Office, you must avoid using this control directly. If you have to provide the functionality of this control, create a "container" control, such as a Microsoft Visual Basic 6.0 UserControl control, an ATL 6.0 Composite control, or an ATL 7.0 Composite control that can host the Rich TextBox Control 6.0. Then, validate the data that the "container" control loads so that the data is safe for initialization. You can use this new control in Office


-------------

2. The IE Security Update disables richtextbox control by setting the killbit in the registry (value Compatibility Flags" on 0x00000400 in "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\ActiveX
Compatibility\{3B7C8860-D78F-101B-B9B5-04021C009402}") if we happen to set the “Compatibility Flags” to Null then it would allow you to add the ActiveX control to Access Forms but its not recommended.
Posted by Chris Crowe on 7/12/2007 7:41 AM

# Can any help me slove this error

Gravatar
I'm now getting this error: Retrieving the COM class factory for component with CLSID {00020819-0000-0000-C000-000000000046} failed due to the following error: 80070005.

followed your tutorial but it errors on, " Dim workbook As New Excel.Workbook()". Can anyone help be figure out how to dix this.
Posted by AV on 7/24/2007 6:08 AM

# "Retrieving the COM class factory for component with CLSID {3B7C8860-D78F-101B-B9B5-04021C009402} failed due to the following er

Gravatar
"Retrieving the COM class factory for component with CLSID {3B7C8860-D78F-101B-B9B5-04021C009402} failed due to the following error: 80040154."

Error occured if Visual Basic dll property not set to Binary Compatibility.
Open VB project and in compile option change it to Binary Compatibilty.
Posted by Chandra Prakash on 9/5/2007 5:18 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Great Post!. One thing I ran into is my application was set to impersonate. So I assume it was using credentialcache and therefore network service or aspnet account wasn't trying to run the process. Just set <identity impersonate="false" /> or make sure the user your using to access the application has launch permissions
Posted by Josh on 9/7/2007 7:03 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks for the article - I'm no longer getting the issue "COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error" - but now excel doesn't open/load from my .NET app at all - any ideas? It works fine on the vs debug server ie localhost:{some port}/mypage.aspx but localhost/mypage.aspx runs fine and appears to do the work - it just never opens excel and displays my report...
Posted by Johann on 9/12/2007 12:23 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Johann- I'm having the exact same issue as you. I haven't found a solution yet... anyone else know of one?
Posted by Mike Branski on 9/14/2007 8:49 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Well - I figured out what's happening - in debug mode the excel process is opened by my user account so obviously , but in normal mode, it's opened by the ASPNET user - I assume this is why the process executes properly, but I can't see it... how do we make excel show on the screen even though it has been executed by the ASPNET user?
Posted by Johann on 9/14/2007 2:08 PM

#  The error is: Retrieving the COM class factory for component with CLSID {00020819-0000-0000-C000-000000000046}

Gravatar
The error is: Retrieving the COM class factory for component with CLSID {00020819-0000-0000-C000-000000000046}

I am getting problems due to this error.Please any one can help me to remove this type of error.
Posted by Rajeev Kumar on 9/21/2007 12:49 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
80070005.

I have set as your instruction but the error still happens. can you help?
Posted by giang on 9/24/2007 11:30 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thank you so much! You helped to resolve my problem which i was trying to fight for nearly one week...
Posted by Anara Davletaliyeva on 10/8/2007 11:33 PM

# Thanks

Gravatar
Thenks for your information about this error !
Posted by Sigit Wibowo on 10/11/2007 8:38 AM

# RE: Word mail merging in asp.net using c#

Gravatar
I tried all settings, as mentioned for Micrisoft.Word - in DCOMCNFG setting and IIS.

Now, application is running without any error but, not showing any generated document. I mean to say not generating anything.

If i use port mode then it will work fine. If i use virtual directory or localhost or launch on production server(win2003) givin error like <Object reference not set to an instance>

Please and Please Help me here

Many thanks in advance for successful solution.
Posted by KRISHNA MOHAN on 10/18/2007 5:06 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Great!
One must not forget to check the "Identity" Tab. If it's set to "this user" and you're not running with the right one, the errors will still be there.
Choose then "the launching user"
Posted by kurisutofu on 11/2/2007 10:20 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Hi. I'm running Vista, and using an object name of "ASPNET" is not accepted. Vista runs IIS 7.0, so i am assuming it is similar to server 2003, as it lets me put in "Network_Services". However, I get the same error. Anyone have any ideas?
Posted by Gable on 11/10/2007 9:29 PM

# re: COM class factory for component with CLSID {0006F0-0000-0000-C000-000000000046} failed due to the following error: 80070005.


hi plz help
Posted by dt on 11/12/2007 10:55 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


hi,

the above article given is meant for win XP and win 2003 server.

but, I have WINDOWS 2000 how can i resolve this error.

please any solution for 2000

its urgent
Posted by rahul on 11/17/2007 12:43 AM

# COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80070005.

Gravatar
The above articale is only for windows XP and 2003 server.

But I have windows 2000.So how i can resolve this error.

Posted by shivanand on 11/21/2007 9:29 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


The article helped me a lot!

THANKS!
Posted by meatloaf on 12/18/2007 8:51 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Right on! You are the man!
Posted by Donny on 12/19/2007 4:46 AM

#  COM class factory for component with CLSID {36D27C48-A1E8-11D3-BA55-00C04F72F325} failed due to the following error: 80070005.

Gravatar
I want to read the MPP file content to xml using asp.net2005...am very new to asp.net ,eventhough i searched a lot and got some stuffs to do it but still i didnt get the apet solution....but in tht whenever am trying to debug the application its throughing the error which i mentioned in the title...i have also checked with the component service in dcomconfig in the security tab......but still am getting the same error....could anyone know how to solve this problem........please kindly help me.........am diging with this problem for such a long time.....its very urgent......

thanks in advance
Posted by sri on 12/28/2007 8:09 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


very good article
<td>umer khan</td>
Posted by umer on 1/24/2008 8:45 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
You can skipp all this , just add next tag <identity impersonate="true" /> in web.config after <authentication mode="Windows" /> .this solve me all he problems.
Posted by pedja on 1/30/2008 1:48 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Hi,

I got the same error when I was doing in Windows server 2003. But the same program is running properly in the windows XP. I have done the above steps by adding "Network Service" and etc.. But still didn't worked.


I made a small change in the web.config with Identity <impersonate=false/> . Before that it was set to true. Suddenly it starts working, but I don't know the exact reason.


Bye,
Posted by vicky on 2/6/2008 6:03 PM

# Retrieving the COM class factory for component with CLSID {741BEEFD-AEC0-4AFF-84AF-4F61D15F5526} failed due to the following err

Gravatar
I have created a windows application in vb.net. In this application I have used the references of "Microsoft Outlook 11.0 Object Library" and "Interop.Redemption.dll". Application is created to read the mails from the local outlook and it is working fine on local machine. But when I deployed it on client machine it is giving me following error.
"Retrieving the COM class factory for component with CLSID {741BEEFD-AEC0-4AFF-84AF-4F61D15F5526} failed due to the following error: 80040154"

mports Microsoft.Office.Interop
Imports System.Windows.Forms
Imports Redemption

Public Class Form1
Inherits System.Windows.Forms.Form
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
TestingCode()

End Sub

Sub TestingCode()

Try
'Dim oApp As Excel.Application = New Excel.Application

Dim myOlApp As Outlook.Application
Dim mpfInbox As Outlook.MAPIFolder
Dim obj As Outlook.MailItem
myOlApp = CreateObject("Outlook.Application")
mpfInbox = myOlApp.GetNamespace("MAPI").GetDefaultFolder(Microsoft.Office.Interop.Outlook.OlDefaultFolders.olFolderInbox)

''''With Redemption''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''
Dim strType As String
Dim objSenderAE As Redemption.AddressEntry ' Redemption.AddressEntry
Const PR_SENDER_ADDRTYPE As Object = &HC1E001E 'MAPI Constant
Const PR_EMAIL As Object = &H39FE001E 'MAPI Constant

Dim j As Integer = 1
For j = mpfInbox.Items.Count To 1 Step -1

Dim objSMail As New Redemption.SafeMailItem 'Create the instance of Redemption.SafeMailItem
objSMail.Item = mpfInbox.Items.Item(j) 'Set the mail item (Microsoft.Office.Interop.Outlook.MailItem) to Redemption.SafeMailItem
objSenderAE = objSMail.Sender

strType = objSMail.Fields(PR_SENDER_ADDRTYPE).ToString ' Get the address type of received mail.
If strType = "SMTP" Then
MsgBox(objSenderAE.Address)
ElseIf strType = "EX" Then
MsgBox(objSenderAE.Fields(Convert.ToInt32(PR_EMAIL)))

End If

Next
Catch ex As Exception
MsgBox(ex.Message.ToString())
End Try
End Class

Anyone can help me in this regard. It's very urgent.
Thanks in advance.

Rahul S

Posted by Rahul on 2/14/2008 2:05 AM

# Getting the Same Error!

Gravatar
i have done all this. i have created a windows service that opens up the outlook on the machine where the windows service is running and then has to loop thro the inbox for a particular message and save it onto a specified location on the disk.
i am using visual studio 2005, .net framework 2.0, outlook 2003.
i am getting this error when i start the windows service.

Service cannot be started. System.Runtime.InteropServices.COMException (0x80040154): Retrieving the COM class factory for component with CLSID {0006F03A-0000-0000-C000-000000000046} failed due to the following error: 80040154.

PLEASE HELP!
Posted by Rekha on 2/19/2008 11:56 AM

# re: COM class factory for component

Gravatar
I followed the steps above, configuring DCOM, and I no longer get the original error. Now I get the following error.

Microsoft Office Excel cannot open or save any more documents because there is not enough available memory or disk space. To make more memory available, close workbooks or programs you no longer need. To free disk space, delete files you no longer need from the disk you are saving to.

I am trying to run this on a Windows 2003 server, using Excel 2007.

it works fine on my local machine.

Any help would be greatly appreciated!!!!

Posted by Christel Lewis on 3/27/2008 3:06 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
I also noticed that I get this error if I try to use interop on a PC that doesn't have office installed. I just wanted to add this in case anyone else is trying to use office interop on XP and is getting this message.

If office is not installed, or the correct version of office for your software is not installed then you will get this error message.

Hope this helps someone,
Jon
Posted by Jon Parise on 4/1/2008 12:57 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Thanks, not it works. In 2003 server giving permission to ASPNET user doesn't work, but giving persmissions to application pool users (in our case NETWORK SERVICE) works.
Posted by Mauro Mazzieri on 4/10/2008 11:30 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following

Gravatar
If you're still having trouble with this on Server 2003, what I did to get this to work was create a new application pool for my web service and have it run under a high privilage user. Then make sure that the DCOM identity is set to this user.

Also, make sure the application's process isn't already running in the background. Use task manager to see if the process is running (check all users). If so, kill it and try again. You'll get an 80080005 error if the application can't launch because it is already launched. (Ran into this problem as well)
Posted by Constantinos Hoppas on 4/17/2008 5:19 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
i also have the same kind of error.
but i m using windows 2000 so the solution which u have provided is not helpful to me.
so please help me to solve my problem in 2000.
Thank u in advance.
Posted by Hussain & Sandeep on 4/18/2008 1:10 AM

# Same Error, but with a windows service ...

Gravatar
Hi,

I get the same error, but with a windows service connecting to a com object. What should I use for the object name in DCOM?
Posted by Jackson on 4/22/2008 2:38 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-

Gravatar
I'd say the user that the service is running as. Go to run, "services.msc" and find your service. Right click on it and go to properties. Click on the Log on tab and you'll see what user to set in DCOM. It's probably Local System.
Posted by Constantinos Hoppas on 4/23/2008 9:14 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Thank you very much! It helped us a lot!!!
Posted by mayvi on 5/7/2008 3:45 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Chris, thanks for sharing the explanation! It helped me a lot :)
Posted by Jaroslaw Dobrzanski on 5/9/2008 1:04 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Thanks a lot.I was searching for two days.It's working now.
Posted by A.Rexy on 5/9/2008 2:38 PM

# COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80070005.

Gravatar
I got this error now:
Microsoft Office Excel cannot open or save any more documents because there is not enough available memory or disk space. To make more memory available, close workbooks or programs you no longer need. To free disk space, delete files you no longer need from the disk you are saving to.

If you set the <identity impersonate="true"/> in the web.config file, it works !!!! Buuuuut the application performance is now sacrified.

Does anyone know how to fix this without the <identity impersonate="true"/>
Posted by Juan Diego on 5/21/2008 5:54 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks a lot. this article was very help full for me to fix this same problems.
Keep up.
Posted by Ashaar on 6/19/2008 10:06 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks a lot Chris. It solved my problem immediately after I did what you explained.
Posted by paul on 6/25/2008 3:44 AM

# Retrieving the COM class factory for component with CLSID {73A4C9C1-D68D-11D0-98BF-00A0C90DC8D9} failed due to the following err

Gravatar
Hi,

I have written code for displaying Access form via C#.net.It works fine when the application is debugged, but when i publish it , it displays a blank page.When i open the task manager , i see instances of MSACCESS open.
I have given rights in DCOM for ACCESS.
Kindly Help.

Shruti
Posted by Shruti Modak on 6/30/2008 11:52 PM

# Great


Thanks, it works great.
First I solved it with impersonation but this solution is best.
Posted by Paulo Gonçalves on 7/8/2008 10:29 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


yeah man, it was a nightmare before I discovered this article. Thanks a lot!
Posted by jan on 7/9/2008 9:27 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
good article tnks
Posted by rejith on 7/14/2008 1:51 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
hi,
I am also facing same type of problem but my problem is that my code is working fine on localhost but when i deployed it on my remote server it show error.

My complied code is also working fine on local IIS.

Plz help me what can i do.

Thanks in advance.
Posted by Ashish Singh on 7/15/2008 9:29 PM

# COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80070005.

Gravatar
I m getting the same problem when i try to export events to outlook.
its wrking fine with out hosting in server.

can anyone help
thanks
Posted by Anoop on 8/4/2008 11:41 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
i get this
Parser Error Message: It is an error to use a section registered as allowDefinition='MachineOnly' beyond machine.config.

if i use
<identity impersonate="" />

and i dont have direct access to server Configure DCOM is not possibe
Posted by koshy on 8/6/2008 9:55 PM

# re: COM class factory for component - WINDOWS FORMS


HI all,

I had this problem when I specified the wrong parameter when adding a workbook to an excel application. Simple fix is to do it right...

using Excel = Microsoft.Office.Interop.Excel;

Excel.Application excel = null;
Excel.Workbook workbook = null;

//Wrong: workbook = excel.Workbooks.Add(new Excel.Workbook());
excel = new Excel.Application();
workbook = excel.Workbooks.Add(Excel.XlWBATemplate.xlWBATWorksheet);

Hope this helps.
Posted by Aonach Mor on 8/11/2008 8:31 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Hello,

Excel file is getting open over localhost FINE.
Getting same error when i deployed it on my remote server.

Plz help me what can i do.

Thanks.,
Posted by Rupesh on 8/20/2008 9:02 PM

# help ayuda

Gravatar
necesito ayuda tengo el mismo problema con una aplicacion pero con word en un servidor xp ya me funciono pero a lo que pongo en windows 2003 server me da el error de fallo el comando y me parece que es a lo que intento abrir el documento de word
les resumo mi aplicacion es en asp net 2005 que genera un documento de word 2003 si alguien sabe que por favor me ayude tambien genero uno de excel el cual se genera normalmente que puede ser solo me falta el de word y le hice lo mismo en ambos en los componentes DCOM de aplicacion de excel y documento de word ayuda por favor
Posted by darwin on 9/3/2008 8:45 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Really excellent
Posted by Nagaraju on 9/3/2008 10:32 PM

# re: COM class factory for component with CLSID {179994C4-D22C-4205-8883-54A79303136B} failed due to the following error: 8007000

Gravatar
Hi there,

i am trying to run Peachtree accounting SDK but the application is throwing the above exception in formload.
under frmMain_Load
Connect.ConnectToPT()
--Connect class
Module Connect
Public App As PeachtreeAccounting.Application
Public Login As New PeachtreeAccounting.Login


Public Sub ConnectToPT()

App = Login.GetApplication("UserName", "Password")
End Sub
End Module
i have made necessary changes in dcomcnfg but still the result is same.

pls help.

Thanks
Posted by Shas on 9/9/2008 10:32 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
If any one still have problems with the COM CSLID then set the Reference to the DLL from the Place it was created the reason for getting all the com errors is only because of not setting the reference properly. after breaking my heads for such a long time i found this was only reason for getting the com error
Posted by Narayanan on 10/22/2008 10:19 PM

# Retrieving the COM class factory for component with CLSID {00020819-0000-0000-C000-000000000046} failed due to the following err

Gravatar
Hi i am getting "Retrieving the COM class factory for component with CLSID {00020819-0000-0000-C000-000000000046} failed due to the following error: 80040154." this error while exporting data to excel.

I foolowed the same steps above you metioned. But still i am getting the same error.

any help would be appreciated.

Thanks in advance.

Regards
------
Shiva
Posted by Shiva on 11/1/2008 11:46 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
i followed the steps given above but the error is still there
so pls short out the Problem
Posted by Arvind singh on 11/15/2008 6:27 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks for detailed walk through.
Posted by RaviBabu Pathuri on 11/20/2008 1:26 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Thanks for your detailed solutions.

I have changed my XP/DCOM security tab.

It is working fine.

Thanks again
Posted by Rameskumar on 11/20/2008 2:14 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
i have done all these thing but in my server is window 2003 server os and problem is not resolved please give me solution




With Regards

Dheeraj Srivastva
Posted by Dheeraj Srivastava on 12/10/2008 5:03 AM

# I found the solution for this.

Gravatar
Hi All,
I found the solution for this issue.

Please remove Microsoft office and re-install with typical installation(no custome installation please).

This was solved my problem.
Posted by umesh chape on 12/11/2008 9:30 PM

# Retrieving the COM class factory for component with CLSID {1CA8A500-E55C-11CF-9D38-00A02457680B} failed due to the following err

Gravatar
I am using IDMObjects, it is working fine in my local pc, when migrate .NET to server and run, it occur error and showing the above error msg. Is it i need to register something in regedit? Please HELP!!
Posted by Katherine on 1/12/2009 8:15 PM

# COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 80070005.

Gravatar
Dear all,

My problem solved and i having another problem that is

When i publish a page in one pc and while try run in another pc it executed but when i click mail merge button it open the wor document where i have publish a page...

Please help me to solve the problem..

Please Mail me:sujayathm@hotmail.com

Regards..
Sujayath
Posted by Sujayath Hussain on 1/23/2009 12:55 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks a lot, great examples!
Posted by Franz on 1/31/2009 2:18 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Try to add following key in the registry if you have tried the above steps and still failing. Save below text as .reg file and double click to add it to registry. You can also alternatively create an entry if it does not exists.

REGEDIT4

[HKEY_CLASSES_ROOT\AppID\WINWORD.EXE]
"AppID"="{00020906-0000-0000-C000-000000000046}"
Posted by Mahendra Kumar Srivastava on 2/17/2009 10:31 PM

# xp with office 2007


When I try to use this method with office 2007, I dont get any error, and aspnet opens an excel.exe process.. but nothing happens after that..if i kill the process, the webpage displays 'request timed out'

Posted by Akshat Kaul on 2/25/2009 5:18 AM

# COM class factory for component with CLSID {733B5232-3E32-46E9-A19F-4A3C05358CCE} failed due to the following error: 80040154.

Gravatar
Hello, I have the problem with:

An error occurred creating the form. See Exception.InnerException for details. The error is: Retrieving the COM class factory for component with CLSID {5FC77827-56BF-459E-9168-D060B7074008} failed due to the following error: 80040154.

This error is have where I run my winform, The code is:

Imports PQ.CHARTrunner

Public Class Form1
Public G_oCrDotNetApp As New CrDotNetApp

the line : Public G_oCrDotNetApp As New CrDotNetApp ... is the make the error, I dont know

I train make a Graph with Chartrunner SDK ( http://www.chartrunner.com/sdk )

Thk for you helps

PD.. sorry by my English


Posted by Emerson Aguilar on 5/6/2009 11:10 AM

# Unable to Authorize Launch Permissions for missing "Microsoft Excel Application" in DCOM Config


Hi,

I would like to develop Excel charts programatically using VB .NET and the Microsoft Excel 11.0 Object Library (http://www.beansoftware.com/asp.net-tutorials/generating-excel-reports.aspx). To accomplish this, I need to authorize the aspnet user on my machine launch permissions on "Microsoft Excel Application" DCOM (http://blog.crowe.co.nz/archive/2006/03/02/589.aspx). I tried using dcomcnfg.exe to do this, however, I cannot find the "Microsoft Excel Application" DCOM under DCOM Config.

I am developing on a Windows XP (work machine) using Office Excel 2003

Why is the ""Microsoft Excel Application" missing in DCOM Config? More importantly, how can I give aspnet launch privileges to if Microsoft Excel Application DCOM is missing in DCOM Config?

Thanks,

Marc
Posted by Marc on 5/14/2009 4:56 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


For those of you who get the below error:
Microsoft Office Excel cannot open or save any more documents because there is not enough available memory or disk space. To make more memory available, close workbooks or programs you no longer need. To free disk space, delete files you no longer need from the disk you are saving to.

please try the below items. it may help you.
1) My app was set for windows authentication. Though, if impersonation set to true may solve the problem, i opted out of that idea because of windows authentication. created a new local security account with needed rights over the required folders and set the account to "This User" under the Identity tab of the MS excel application properties.
2)Also, did "Access permissions" --> enable "Customize" --> click "Edit". click Add --> choose the needed accounts / everyone. Enable "Local access".
Thats it. your above error should be resolved.
My solution is for those who face my situation (i.e.) with windows authentication, but cannot enable impersonation and still want excel generated for everyone.
Posted by VictoryKing on 5/27/2009 11:58 AM

# The error is: Retrieving the COM class factory for component with CLSID {00020819-0000-0000-C000-000000000046}

Gravatar
I check access to the com and the registry, but i have the same message.

Please, help me.
Posted by Pedro Soto on 8/5/2009 8:13 AM

# Error Code: 8000401a.

Gravatar
System.Runtime.InteropServices.COMException: Retrieving the COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8000401a.

Please provide me the Solution ASAP......

Please help me....
Posted by Ketan Udani on 8/12/2009 2:26 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
Man... you are the master of masters... I lost a big amounth of time trying to find the right answer until came here... thanks
Posted by Sebastian Greco on 8/28/2009 3:29 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000

Gravatar
can i solve this error without installing microsoft office
Posted by kiran on 9/3/2009 8:39 PM

# Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following err

Gravatar
Hi I got this problem
Retrieving the COM class factory for component with CLSID {000209FF-0000-0000-C000-000000000046} failed due to the following error: 80070005.

when I'm trying to give content of document file to textbox.
What should I do to solve this issue.

Posted by Saket on 9/4/2009 9:21 PM

# Retrieving the COM class factory for component with CLSID {00020906-0000-0000-C000-000000000046} failed due to the following err

Gravatar
Hi,

I developed ASP.NET web application in VS 2005 c# for generating reports in ms word. It is working in my local machine. But when I try to publish the site and hosted in server ,then its not working am getting the error is : Retrieving the COM class factory for component with CLSID {00020906-0000-0000-C000-000000000046} failed due to the following error: 80080005.
I did all the setting in DCOM configuration but still I am facing the same issue ,could you please me some one it is very urgent.

Regards
Anish
Posted by Anish on 9/7/2009 7:44 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


I believe the solution is pointed out by Mahendra Kumar Srivastava (2/17/2009 10:31 PM)
This is what I found the MS Forum as well.
Try and revert!
Posted by Prasad Gupte on 9/8/2009 6:19 PM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Thanks! This was very helpful. Now our web application is able to use the Excel com object hosted on a 2003 server.
Posted by Chris Demaria on 10/3/2009 3:49 AM

# re: COM class factory for component with CLSID {00024500-0000-0000-C000-000000000046} failed due to the following error: 8007000


Hi
I am having this problem in Windows 7. I cannot find the Microsoft Excel Application in the DCOM Config item. Does anyone know how to fix this issue?
Regards, Christian
Posted by Christian on 11/19/2009 10:19 PM

Post Comment


Title *
Name *
Email
Url
Comment *  
Please add 5 and 2 and type the answer here: