Connecting to password protected Accsses database

Mladen

Member
Joined
Feb 6, 2003
Messages
17
Can someone tell me how can I connect to an Accsses 2000 database protected with password.It seems that I cannot write the ConnectionString wright.
 
The error I get is:
"Cannot start your application. The workgroup information file is missing or opened exclusively by another user"
Can anyone help?
 
Try to use a connection string similar with this:

Provider=MSDASQL.1;Password=password;Persist Security Info=True;Extended Properties="DRIVER={Microsoft Access Driver (*.mdb)};DBQ=c:\Test.mdb;
 
enter ur Jet OLEDB:Database Password

when u r using access u need to set up ur "Jet OLEDB:Database Password" - this is not the first pass asked in the conn string.

i think that will fix it, make a new connection named conn1 and copy this:

only change ur_db_path ( ex : c:\temp\my.mdb)
and fill_in_ur_pass! (ex : gimmemoney)

everything that is in " - has to be in double "" - if u set up the parameters by string


conn1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Password="""";User ID=Admin;Data Source=ur_db_path=Share Deny None;Extended Properties="""";" _
& "Jet OLEDB:System database="""";Jet OLEDB:Registry Path="""";Jet OLEDB:Database Password=""fill_in_ur_pass!"";Jet OLEDB:Engine Type=5;Jet OLEDB:Database Locking Mode=1"

i hope that works peet
 
peet, it works great.
Where are you,I want to buy you a drink?
I tried the exact same string only with the single quotes.
You saved me a lot of trouble
thanks
 
Back
Top