C# to create an access database....with password protection.

  • Thread starter Thread starter Rick Doll
  • Start date Start date
R

Rick Doll

Guest
I have successfuly created access databases but is there something I can place in the code to have the database created have a password added to it?


try
{
Catalog cat = new Catalog();
string strCreateDB = "";
strCreateDB += "Provider=Microsoft.Jet.OLEDB.4.0;";
strCreateDB += "Data Source=" + pstrDB + ";";
strCreateDB += "Jet OLEDB:Engine Type=5";
cat.Create(strCreateDB);
}//closes try.
catch (Exception)
{

}//closes catch.

Continue reading...
 
Back
Top