Unable to open a pw-protected mdb 
Author Message
 Unable to open a pw-protected mdb

Hi,

I have got a write protected Microsoft Access 2000 database and I want to
open it with ADO.
But when opening the connection, I always get a response that the password
is incorrect.
The problem only exists if the database is write protected. If I remove the
write protection, my program opens the connection without any problems.

Here's the line that shall open the database (it's Pascal syntax):
conn.Open('DRIVER={Microsoft Access Driver (*.mdb)}; DBQ='+CDBPath, '',
getPW, adConnectUnspecified);

Anything I'm doing wrong?

Bye
Christian



Tue, 04 May 2004 17:13:53 GMT
 Unable to open a pw-protected mdb

You need to specify the database password in an obscure property on the ADO
connection object, as follows:

conn.properties("JET OLEDB:Database Password") = "yourpassword"

This approach requires the use of the Microsoft Jet OLEDB Provider 3.51 or
4.0; this is the recommended provider for ADO access to Jet databases.

See the following Knowledge Base article for further information:

Q191754: HOWTO: Open a Secured Access Database in ADO Through OLE DB
http://support.microsoft.com/support/kb/Articles/q191/7/54.asp

Steven Bras, MCSD
Microsoft Developer Support/Visual Basic WebData

This posting is provided "AS IS" with no warranties, and confers no rights.



Sat, 08 May 2004 03:24:25 GMT
 
 [ 2 post ] 

 Relevant Pages 

1. how to repair a pw protected mdb ?

2. open pw protected access db without Jet??

3. Newbie: Open write-protected MS-jet (.mdb) database?

4. Problem opening a password protected .MDB

5. Opening a password protected MDB file using ADO

6. Open the password protected MDB with VB

7. Open MDB protected with password from Visual Basic

8. unable to open Access2000 mdb in VB6

9. Question - Making Access DB pw protected Then Accessing that pw protected DB from code - How?

10. Unable to open a mdb database...

11. Unable to open .mdb file

12. Help on PW protected Access files


 
Powered by phpBB® Forum Software