Solved

Doesn't recognize the ADODB variable types

Posted on 2007-03-29
6
438 Views
Last Modified: 2008-03-06
I am getting the following Visual Basic error in an Access Database (mdb):

Compile error:
User-defined type not defined

The variable that it doesn't recognize is "New ADODB.Recordset"

This database has worked just fine without any issues. Now it doesn't recognize the ADODB variable types.
0
Comment
Question by:tiggermt
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 34

Expert Comment

by:jefftwilley
ID: 18820635
What's changed in your environment? This usually indicates that an update or some other upgrade has either moved or overwritten DLLs on the offending machine. Have you opened the DB up and checked for any missing references?
J
0
 
LVL 61

Accepted Solution

by:
mbizup earned 125 total points
ID: 18820643
Make sure that you have your references set up properly:
From the VBA Editor:

Tools -> References
Make sure that
Microsoft Activex Data objects Librery v x.x   is checked

If it is checked and labelled MISSING, uncheck it and select the right version from the list.
Click OK to save and exit
0
 
LVL 67

Assisted Solution

by:sirbounty
sirbounty earned 125 total points
ID: 18820648
Check Project/References - make sure you've still got reference to Microsoft ActiveX Data Objects 2.x Library
0
MS Dynamics Made Instantly Simpler

Make Your Microsoft Dynamics Investment Count  & Drastically Decrease Training Time by Providing Intuitive Step-By-Step WalkThru Tutorials.

 
LVL 75
ID: 18820665
in case the References suggestions does not fix this ... can you post all the relevant code?

mx
0
 

Author Comment

by:tiggermt
ID: 18820738
Thanks! It was the references.
0
 
LVL 34

Expert Comment

by:jefftwilley
ID: 18820743
Happy to help
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In earlier versions of Windows (XP and before), you could drag a database to the taskbar, where it would appear as a taskbar icon to open that database.  This article shows how to recreate this functionality in Windows 7 through 10.
In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question