Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using DAO objects in Excel 1

Status
Not open for further replies.

flugh

Technical User
Aug 23, 2002
655
0
0
US
I have an example of how to take information from an Access database and add it to an Excel worksheet. I've modified the code to fit my needs, everything works fine. However, if I create a new workbook, then paste the working code into it, the code dies as soon as I do:

Dim dbs as DAO.database

It says this is some unknown user-defined datatype or object. I haven't found anything in the helpfiles about enabling this functionality, no "object inserted" to make it happen or anything. My code works if I keep copying the original example workbook, but not if I start from scratch.

This is more of an annoyance than anything else. The job is getting done. I'm just not fond of employing voodoo to make my projects work :)

Any tips/advice would be greatly appreciated!
 
That's what I was missing. Thanks a lot!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top