Can'd add DAO reference. Even to brand new db. (1 Viewer)

SyntaxSocialist

Registered User.
Local time
Today, 11:37
Joined
Apr 18, 2013
Messages
109
Can't add DAO reference. Even to brand new db.

Hello all. Very confused right now. I have an existing db, and I need to add the DAO library reference to get it to work the way I want (see here for an explanation). I keep getting an error when I try to add the reference, though: "Name conflicts with existing module, project, or object library"

I can't for the life of me figure this one out, as none of my names should be conflicting with Access, and I even tried making a new db (johnd) with a table (tbljohnd) and a blank form (frmjohnd). Tried to add the DAO reference to the empty frmjohnd module, but I got the same error.

Anyone have any ideas here?

Edit: Silly me, I forgot to list my existing references:
- Visual Basic For Applications
- Microsoft Access 12.0 Object Library
- OLE Automation
- Microsoft Office 12.0 Access Database engine Object Library

Those were all there by default when I created that new database, and they're also the only ones present in the existing db that I'm trying to troubleshoot. And the error occurs no matter which DAO version I try to add.
 
Last edited:

KenHigg

Registered User
Local time
Today, 11:37
Joined
Jun 9, 2004
Messages
13,327
Are you saying that your code won't compile? If so can you post the code and the line number where the error occurs?

Edit: Never mind, I understand. What is the exact name of the DAO lib you're add?
 

SyntaxSocialist

Registered User.
Local time
Today, 11:37
Joined
Apr 18, 2013
Messages
109
Ken: Even in the new (practically empty) db, the "code" which is really just a blank module will compile, but I can't add the reference. As it happens, I am having a bit of trouble getting the existing db's code to compile, but even if I comment out the troublesome parts and get it to a point where it compiles, I can't add the reference.
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 08:37
Joined
Aug 30, 2003
Messages
36,118
Have you tried adding DAO functionality without it? You don't need that reference in an accdb.
 

KenHigg

Registered User
Local time
Today, 11:37
Joined
Jun 9, 2004
Messages
13,327
Try deleting ref's and adding the new dao ref until you see which two don't get along.
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 08:37
Joined
Aug 30, 2003
Messages
36,118
Try deleting ref's and adding the new dao ref until you see which two don't get along.

It's

Microsoft Office 12.0 Access Database engine Object Library

because it includes DAO.
 

KenHigg

Registered User
Local time
Today, 11:37
Joined
Jun 9, 2004
Messages
13,327
I think he said it would not compile as-is.
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 08:37
Joined
Aug 30, 2003
Messages
36,118
I think he said it would not compile as-is.

Yes, but:

"but even if I comment out the troublesome parts and get it to a point where it compiles, I can't add the reference. "
 

KenHigg

Registered User
Local time
Today, 11:37
Joined
Jun 9, 2004
Messages
13,327
I see. Wonder what pc(s) of code it zonks on. It may not be a bad ref error...

Edit: Probably what you've been getting at all along...
 

SyntaxSocialist

Registered User.
Local time
Today, 11:37
Joined
Apr 18, 2013
Messages
109
It's

Microsoft Office 12.0 Access Database engine Object Library

because it includes DAO.

pbaldy nailed it. Did not know it included DAO. Okay, so that should help me narrow down where the problems are coming from in my existing code. I can rule out DAO not being an active reference. Thanks :)
 

gemma-the-husky

Super Moderator
Staff member
Local time
Today, 15:37
Joined
Sep 12, 2006
Messages
15,613
so it's probably your code rather than the reference. can you show us the code that isn't working, please?
 

pkraja

New member
Local time
Today, 08:37
Joined
Nov 6, 2015
Messages
6
I just installed Access 2016 32 bit and ran into this issue of not being to send data to a new record in form. Error '424' Object Required. Does anyone have a suggestion as to how I get around this. I cannot add Microsoft DAO 3.6 Object Library as the name conflicts with an existing library - presumably Microsoft Office 16.0 Access database engine Object Library. I unchecked the latter and checked the former but still get the same error.
 

The_Doc_Man

Immoderate Moderator
Staff member
Local time
Today, 10:37
Joined
Feb 28, 2001
Messages
26,999
pkraja - you have restarted an old thread (from 2013). You might get better results creating a new thread. The names for DAO vs. the database engine libraries should not conflict with one another.
 

Users who are viewing this thread

Top Bottom