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

Password protected Access Database 1

Status
Not open for further replies.

fischadler

Programmer
May 31, 2002
258
MT
I am using the code below to access an Access database:

Code:
set Con = Server.CreateObject("ADODB.Connection")
DSNtemp="DRIVER={Microsoft Access Driver (*.mdb)}; "
DSNtemp=DSNtemp & "DBQ=" & server.mappath("mydb.mdb")
Con.Open DSNtemp

What should I add to this code if the database is password protected?

Thanks
 
Something like this:

oConn.Open "Driver={Microsoft Access Driver (*.mdb)};" & _
"Dbq=" & Server.MapPath(".") & "\myDb.mdb;" & _
"Uid=admin;" & _
"Pwd=gdfgdfg"

-L
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top