Software Development Network>> .NET Development>> how to change ms access database password in c#?
I doubt it's possible.
Charles
First you need to open the database for exclusive access. Below is a sample connection string:
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Test Files\Access2000.mdb;Jet OLEDB:Database Password=currentpassword;Mode=Share Exclusive"
Then you can execute the following Jet SQL (ExecuteNonQuery):
"ALTER DATABASE PASSWORD newpassword currentpassword"
how to change ms access database password in c#?
Evan Mulawski
I doubt it's possible.
Charles
schmod54
First you need to open the database for exclusive access. Below is a sample connection string:
"Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Test Files\Access2000.mdb;Jet OLEDB:Database Password=currentpassword;Mode=Share Exclusive"
Then you can execute the following Jet SQL (ExecuteNonQuery):
"ALTER DATABASE PASSWORD newpassword currentpassword"
Jonas.S
acf
Yes, I believe you specify the new password value as Null.
John Mathews
pasha2k