Runtime error '3085'

J

Jason

I get run-time error '3085':
Undefined function 'DLookup' in expression.

This has just occured after deleting the form and copying a form from
another table. This code worked fine until I tried replacing the form with a
later one.

Thanks,
Jason.
 
J

Jeanette Cunningham

Hi Jason,
open the form in design view and then open the code window for that form.

In the code window, select Debug | Compile
If the code doesn't compile, fix the errors until it does compile.


Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia
 
J

Jason

there are no errors. The database works fine on this computer but when I
copy on to mine I immediately get the error.
 
J

Jeanette Cunningham

Check your references in your database on your computer.
Press Ctl + G to open the immediate and code windows.
On the menu choose Tools | References

There are 3 standard references needed for an access databases, more can be
used, but the 3 standard ones need to be there.
The one that is most likely missing from your database is Microsoft DAO 3.6
Object Library.
Scroll down the list, find the DAO 3.6 one, check it so that the tick
appears, then click OK.
Now close the references dialog.
Do a Debug compile.
See if the error goes away.


Jeanette Cunningham MS Access MVP -- Melbourne Victoria Australia
 
J

Jason

I have checked references.
Visual Basic
DAO 3.51
Access 8 Library

Unticking DA0 351 and ticking 3.6 worked.

Thanks,
Thanks,
J.
 
J

Jason

Strange thing is: DAO 3.51 works on this computer but not mine.
(Use Access 97 as this is the run time version I have)

This one:
Access 97 and 2000

Mine:
Access 97 and 2003

Maybe the VBA side of it doesn't relate directly to Access.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top