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

Data Control

Status
Not open for further replies.

DevonTaig

Programmer
May 2, 2001
73
US
I have an Access database that is password protected. Because the database is password protected, when I try to set the RecordSource property of the DataControl to a table in the database, I get an "Invalid Password" error at runtime. I know the password for the database, but I don't know how to pass it to the data control. Is there some other way of doing this?

I also tried using an ADODC control...With it, I can supply the password and connect to the database without a problem, but, unfortunately, I can not link an OLE Container Control to an ADODC control (the OLE Container Control does not support ADODC).

Kieren
 
How about using ADODB?

With ADODB, you can set the user name and password, then call a recordset. I have not tried to connect an ADODB recordset to a Data Control, but it should be possible.

Another option is to create an ODBC link. I have used this several times. When I start my project, I look for the link, if it doesn't exist I create it. The ODBC link also houses the username and password thereby eliminating the need to pass this information to any controls.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top