CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7
  1. #1
    Join Date
    May 2010

    -2147319779 (8002801d) Automation Error - Library Not Registered

    I created an input request form database using Access 2003 which automatically creates an email using VBA to create the email. In the VBA environment, I selected the reference to the Microsoft Outlook 11.0 Object Library. This program works fine on all computers using Windows XP but we recently purchased a laptop with Windows 7 running Office 2003 and on that computer the runtime error -2147319779 (8002901d) Automation error - library not registered occurs. I believe the problem is a DLL file that is missing but have no idea which DLL file. Does anyone have any suggestions on how to fix this problem? I have included the code and where the error occurs for reference:

    Private Sub cmdSubmitRequest()

    Dim olApp As Outlook.Application
    Dim olNS As Outlook.NameSpace
    Dim olfolder As Outlook.MAPIFolder
    Dim olMailItem As Outlook.MailItem

    Dim varBodyText As Variant
    Dim strName As String
    Dim strDepartment As String
    Dim strChargeNumber As String

    Dim strRequiredDate As String
    Dim strRequestDate As String
    Dim strAddtionalInfo As String

    Dim strWorkLocation As String
    Dim strProductType As String

    strName = "Last Name: "
    strDepartment = "Department: "
    strChargeNumber = "Charge Number: "
    strRequiredDate = "Date Wanted: "
    strRequestDate = "Date Written: "
    strWorkLocation = "Location: "
    strProductType = "Product Type: "
    strAdditionalInfo = "Description of Work: "

    Set olApp = CreateObject("Outlook.Application") Runtime Error Occurs At This Line of Code

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

    This is only partial code. I did not want to bore you with details.

    I appreciate any help you can give me. We will be in a transition period for some time running both Windows XP and Windows 7 so this will be an ongoing problem. Thank you for your help.

  2. #2
    Join Date
    Apr 2009

    Re: -2147319779 (8002801d) Automation Error - Library Not Registered

    Let me be cap'n obvious here, but have you checked to make sure that the outlook application was installed? If it is installed, has it been run the first time? Set up correctly? Send/recive emails as if user was operating?

    Good Luck

  3. #3
    DataMiser is offline Super Moderator Power Poster
    Join Date
    Jul 2008

    Re: -2147319779 (8002801d) Automation Error - Library Not Registered

    I started to give the same response earlier but .....
    Always use [code][/code] tags when posting code.

  4. #4
    Join Date
    May 2010

    Re: -2147319779 (8002801d) Automation Error - Library Not Registered

    The computer is setup with Office 2003 professional and Windows 7 professional. All Outlook functions work properly. I am able to send and receive email manually just not programatically. My suspician is that the Microsoft Outlook 11.0 Object Library or one its components is not registered properly and therefore can not be found. I need help determining the names of the DLL files so I can use regsvr32.exe to register the libraries properly. Thank you for any help you can give me.

  5. #5
    Join Date
    Jan 2006
    Fox Lake, IL

    Re: -2147319779 (8002801d) Automation Error - Library Not Registered

    Turn off Antivirus and Firewall, and temporarily turn of UAC, and it'll probably work.

    With the combination of those three items, plus Windows 7, I'l guess that it's not likely to happen

    CodeGuru Article: Bound Controls are Evil-VB6
    2013 Samples: MS CODE Samples

    CodeGuru Reviewer
    2006 Dell CSP
    2006, 2007 & 2008 MVP Visual Basic
    If your question has been answered satisfactorily, and it has been helpful, then, please, Rate this Post!

  6. #6
    Join Date
    Oct 2013

    Re: -2147319779 (8002801d) Automation Error - Library Not Registered

    This worked for me! life saver! i have spend days trying to get my macro to work. thank you

  7. #7
    Join Date
    Jul 2001
    Sunny South Africa

    Re: -2147319779 (8002801d) Automation Error - Library Not Registered

    I am glad that you have found a problem to your solution. But, this is a 3 year old thread..

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Windows Mobile Development Center

Click Here to Expand Forum to Full Width

On-Demand Webinars (sponsored)

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.