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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ODBC connection

Status
Not open for further replies.

savok

Technical User
Jan 11, 2001
303
AT
Can anyone give an example on how I would connect to ODBC using VB?

Also anyone have a clue why the following line

Dim db as database

gives me this error?
'User-defined type not defined'

thanks
 
Hi

VB does not automaticaly reference the DAO controls and this means Database has not been defined as a type.

You need to go to the PROJECT menu, then REFERENCES and in the list you are given you will be able to tick Microsoft DAO (version) Libary.

This includes all the variables and events you need.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top