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.