-
May 24th, 2002, 12:12 AM
#1
How to connect 2 password-protected MDB
Hi,
How do you do this? Is it in the connection string? If yes, could you give me an example; I am using MSAccess 97. Thanks.
-
May 24th, 2002, 12:19 AM
#2
It seems pretty simple. I faced problem while using a provider for a dsn-less connection though.
May be any guru would care to tell if provider works for a password protected mdb, and how.
This is my class for creating a global connection object
Code:
Private Sub Class_Initialize()
Set cn = New ADODB.Connection 'public connection object
With cn
.CursorLocation = adUseClient
.ConnectionString = "DSN=dsnname;UID=admin;PWD=pwd;"
.Open
End With
End Sub
Last edited by debuchakrabarty; May 24th, 2002 at 12:23 AM.
Regards
Debashish Chakrabarty
SCJP
******************************
Cool Site for SCJP aspirants at:
http://www.geocities.com/wahjava
******************************
-
May 24th, 2002, 12:29 AM
#3
debuchakrabarty or anybody,
That's exactly my problem, I don't want to use a DSN connection. Is it possible to use a DSN-less connection to access a password-protected mdb? How?
-
May 24th, 2002, 01:27 AM
#4
Accessing Password Protected Access Database
Hello Buddy:
Well to access the password protected database, without a dsn you have to use the following connection string
(To access a Database having password on the Databse Level)
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=Test.mdb;Jet OLEDBatabase Password=abc
(To access a Database having password on the user Level)
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=Test.mdb;User id=ky;password=abc
I hope that it solves ur problem
-
May 24th, 2002, 01:42 AM
#5
Mr. Kyakub,
I used your 1st ex since it's protected at db level, but it returned an error:
-2147467259: Could not find installable ISAM.
What could be the problem now?
-
May 24th, 2002, 03:12 AM
#6
Goto microsoft download center, and search for "Jet" and or "Isam".
You should find latest release of it (jet 4.0...), which is not included in MDAC_TYP.exe
This should solve the matter
Cesare
...at present time, using mainly Net 4.0, Vs 2010
Special thanks to Lothar "the Great" Haensler, Chris Eastwood , dr_Michael, ClearCode, Iouri and
all the other wonderful people who made and make Codeguru a great place.
Come back soon, you Gurus.
-
May 24th, 2002, 04:02 AM
#7
Provider Problem
I downloaded the Jet40SP6_9xNT.exe for winnt and installed. However now on running 'ADO could not find the specified provider' error comes.
Regards
Debashish Chakrabarty
SCJP
******************************
Cool Site for SCJP aspirants at:
http://www.geocities.com/wahjava
******************************
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|