LJG
asked on
ActiveX component can't create object - Email thru Outlook
Problem
I get the error "ActiveX component can't create object" on the 2nd line of code in Access 2003. Same database (mdb) opened in Access 2010 it works without problems.
Dim objOutLkApp As Object
Set objOutLkApp = CreateObject("Outlook.Appl ication")
Some Facts
1) Use the same code all the time for my customers with Access 2003 & Outlook 2003
2) I was adding email capability to an app and discovered the error on my machine.
3) I have installed Office 2010 but kept Access 2003
4) I have no missing references and I do not reference Outlook reference library - I like using late binding on purpose.
5) I've tried referencing Microsoft Outlook 14.0 Object Library with the following code, but got the same error (Early Binding).
Dim objOutLkApp As Outlook.Application
Set objOutLkApp = New Outlook.Application
6) Telling my customers to upgrade to 2010 is not an option
Any Thoughts?
Thanks for any help
LJG
I get the error "ActiveX component can't create object" on the 2nd line of code in Access 2003. Same database (mdb) opened in Access 2010 it works without problems.
Dim objOutLkApp As Object
Set objOutLkApp = CreateObject("Outlook.Appl
Some Facts
1) Use the same code all the time for my customers with Access 2003 & Outlook 2003
2) I was adding email capability to an app and discovered the error on my machine.
3) I have installed Office 2010 but kept Access 2003
4) I have no missing references and I do not reference Outlook reference library - I like using late binding on purpose.
5) I've tried referencing Microsoft Outlook 14.0 Object Library with the following code, but got the same error (Early Binding).
Dim objOutLkApp As Outlook.Application
Set objOutLkApp = New Outlook.Application
6) Telling my customers to upgrade to 2010 is not an option
Any Thoughts?
Thanks for any help
LJG
Is this code creating or opening an email?
If it is, its possible the mapi dlls that allow the MAPIMail Service to run are broken or corrupt.
Could look at renaming/recreating the mapi dlls
http://www.ctimls.com/support/kb/error%20fixes/fix_mapi_error.htm
This usualyl fixes issues sending mail from other apps
If it is, its possible the mapi dlls that allow the MAPIMail Service to run are broken or corrupt.
Could look at renaming/recreating the mapi dlls
http://www.ctimls.com/support/kb/error%20fixes/fix_mapi_error.htm
This usualyl fixes issues sending mail from other apps
LJG,
As a test, how about trying to create an instance of Word or Excel instead of Outlook? The point of the test would be to see if the problem is with Outlook or with any of the Office 2010 apps.
As a test, how about trying to create an instance of Word or Excel instead of Outlook? The point of the test would be to see if the problem is with Outlook or with any of the Office 2010 apps.
ASKER
Lots of good ideas - Just not an answer yet. Any other ideas?
GrahamMandeno
1) It does work with no problems on my laptop (both Access 2003 & 2010) so we know it's something with my desktop.
2) From the Control Panel I repaired Office 2010 / shut down my computer-restarted / Still the same problem.
BlueDevilFan
Dim objOutLkApp As Object
Set objOutLkApp = CreateObject("Outlook.Appl ication")
Set objOutLkApp = Nothing
------------------------ All the below work in 2010
Set objOutLkApp = CreateObject("Outlook.Appl ication") <--- Outlook does not work in 2003
Set objOutLkApp = CreateObject("Word.Applica tion") <--- This Works in 2003
Set objOutLkApp = CreateObject("Excel.Applic ation") <--- This Works in 2003
Other folks - thanks for the links but neither helped.
Any other ideas at this point???
Thanks for all your thoughts.
GrahamMandeno
1) It does work with no problems on my laptop (both Access 2003 & 2010) so we know it's something with my desktop.
2) From the Control Panel I repaired Office 2010 / shut down my computer-restarted / Still the same problem.
BlueDevilFan
Dim objOutLkApp As Object
Set objOutLkApp = CreateObject("Outlook.Appl
Set objOutLkApp = Nothing
------------------------ All the below work in 2010
Set objOutLkApp = CreateObject("Outlook.Appl
Set objOutLkApp = CreateObject("Word.Applica
Set objOutLkApp = CreateObject("Excel.Applic
Other folks - thanks for the links but neither helped.
Any other ideas at this point???
Thanks for all your thoughts.
So it's just Outlook that doesn't work. That's bizarre. What version of Windows is on the computer and is it 32 or 64 bit? Is Access 2003 32 or 64 bit? How about Office 2010?
ASKER
Windows 7 Prof / 64 bit
Office 2010 - 32 bit
Office 2003 - 32 bit
Isn't life suppose to be simpler :)
Office 2010 - 32 bit
Office 2003 - 32 bit
Isn't life suppose to be simpler :)
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks again for the responses.
------------------------ All the below work in 2010
Set objOutLkApp = CreateObject("Outlook.Appl ication.14 ") <--- Outlook does not work in 2003
Set objOutLkApp = CreateObject("Word.Applica tion".14) <--- This Works in 2003
Set objOutLkApp = CreateObject("Excel.Applic ation.14") <--- This Works in 2003
----- In case you want to ask ------------------- Does Not work in 2003 or 2010 ----
Set objOutLkApp = CreateObject("Outlook.Appl ication.11 ")
-------------------------- --
Yes = I've tried it in 3 different 2003 databases.
thanks!
------------------------ All the below work in 2010
Set objOutLkApp = CreateObject("Outlook.Appl
Set objOutLkApp = CreateObject("Word.Applica
Set objOutLkApp = CreateObject("Excel.Applic
----- In case you want to ask ------------------- Does Not work in 2003 or 2010 ----
Set objOutLkApp = CreateObject("Outlook.Appl
--------------------------
Yes = I've tried it in 3 different 2003 databases.
thanks!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Graham
Thanks so much - I have the version below, but I can't do the Com Addins until tomorrow sometime.
?CreateObject("Outlook.App lication") .Version
14.0.0.6131
Thanks
LJG
Thanks so much - I have the version below, but I can't do the Com Addins until tomorrow sometime.
?CreateObject("Outlook.App
14.0.0.6131
Thanks
LJG
Hmmm...
The fact that ?CreateObject("Outlook.App lication") .Version returns any result at all suggests that the problem is NOT with Outlook 2010, and is therefore in Access 2003.
I suggest you move your focus back to Access 2003 and try a Detect and Repair (from the Help menu).
These interoperability problems really can be pigs to solve!
Cheers,
Graham
The fact that ?CreateObject("Outlook.App
I suggest you move your focus back to Access 2003 and try a Detect and Repair (from the Help menu).
These interoperability problems really can be pigs to solve!
Cheers,
Graham
ASKER
Thanks for all the work EVERYONE did for me.
I've taken out all the Outlook Add-ins - shutdown the computer - did not solve the problem.
Sometime in the next two weeks, I'll re-install Office 2010. If that works I'll come back an let everyone know
Go have some fun today - LJG
I've taken out all the Outlook Add-ins - shutdown the computer - did not solve the problem.
Sometime in the next two weeks, I'll re-install Office 2010. If that works I'll come back an let everyone know
Go have some fun today - LJG
Does the problem occur on more than one computer? Usually such a problem is due to a missing or damaged component, or a fault in the registration of the automation server on a single computer. This can be fixed by repairing the installation.
First make sure that all Office apps are closed, then go to Programs and Features in the Control Panel and find Microsoft Office 2010. Right-click on it and click Change. Select Repair and click Continue.
With luck, when the procedure completes your problem should be solved.
Best wishes,
Graham Mandeno [Access MVP 1996-2013]