954,535 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Help ==> DataReprot + Password Protected Database (Urgent)

Hi Everyone
I m trying to open password protected Database for Data Report applying the following Code in Command Button1.

Dim CN As ADODB.Connection
Dim RS As ADODB.Recordset
Set CN = New ADODB.Connection
Set RS = New ADODB.Recordset
CN.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0" & _
";Data Source =" & App.Path & ".\MyDataBase.mdb"

CN.Open
Set RS = CN.Execute("Select * From Tabel1 Where Name ='" & txtName.Text & "'")
Set DataReprot1.DataSource = RS

DataReprot1.Show

But its showing error please, anyone tell me how can I set the connection for password protected Database.

Naveed_Cn
Newbie Poster
10 posts since Jun 2007
Reputation Points: 10
Solved Threads: 0
 

Hi,

open password protected database like this :

CN.ConnectionString = _
"Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source="& App.Path & _
"\MyDataBase.mdb" & ";" & _
"Jet OLEDB:Database Password=MyPWd" 

    CN.Open


Regards
Veena

QVeen72
Posting Shark
950 posts since Nov 2006
Reputation Points: 84
Solved Threads: 143
 

hi veena
our company has a passwor protected database.can we open tthat database.
regards
suneel

Hi, open password protected database like this :

CN.ConnectionString = _
"Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source="& App.Path & _
"\MyDataBase.mdb" & ";" & _
"Jet OLEDB:Database Password=MyPWd" 

    CN.Open

Regards Veena

suneel kar
Junior Poster in Training
71 posts since Jul 2007
Reputation Points: 10
Solved Threads: 1
 

Hi,

If it is in Access, and if u know the Password then u can open it with the above code..

Regards
Veena

QVeen72
Posting Shark
950 posts since Nov 2006
Reputation Points: 84
Solved Threads: 143
 

hi veeeeeeee
if password is known anyone can access the databae. without password is it possible
regards
suneel

Hi, If it is in Access, and if u know the Password then u can open it with the above code.. Regards Veena
suneel kar
Junior Poster in Training
71 posts since Jul 2007
Reputation Points: 10
Solved Threads: 1
 

hi veena
and wt if i ddont know the passwod
regaards
suneel

suneel kar
Junior Poster in Training
71 posts since Jul 2007
Reputation Points: 10
Solved Threads: 1
 

Hi,

Try for some Password Breakers...

I gave the code In view of a "Developer"

Not As A "Hacker"..... :)--Vee

QVeen72
Posting Shark
950 posts since Nov 2006
Reputation Points: 84
Solved Threads: 143
 

This question has already been solved

Post: Markdown Syntax: Formatting Help
You