p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/)
-   BOOK: Access 2003 VBA Programmer's Reference (http://p2p.wrox.com/book-access-2003-vba-programmers-reference-133/)
-   -   Automation Error - Library Not Registered (http://p2p.wrox.com/book-access-2003-vba-programmers-reference/79453-automation-error-library-not-registered.html)

DMothes May 18th, 2010 08:44 AM

Automation Error - Library Not Registered
 
Please Help!!!! When I run the code below in a Windows 7 environment I get an error: Automation Error - Library Not Registered. This code works great in Windows XP with Access 2003. I think this has something to do with a missing DLL file but I am not sure. Does anybody know how to resolve this problem?


Set olApp = CreateObject("Outlook.Application")

Set olNS = olApp.GetNamespace("MAPI")
Set olfolder = olNS.GetDefaultFolder(olFolderInbox)
Set olMailItem = olfolder.Items.Add("IPM.Note")

Thank you for any help you can give.

Harry November 28th, 2011 09:31 AM

You should check the references in your database. Search for the outlook reference (Microsoft Outlook ..... Object library) and add it to your references.
That should help.


All times are GMT -4. The time now is 07:15 PM.

Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
2013 John Wiley & Sons, Inc.