6
Answers

Problem connecting to Access database with user level security

Ask a question
Igor

Igor

14y
2.8k
1
I have a problem connecting to an Access database with user level security from C# program.
The connection string is:
 connStr = "Provider=Microsoft.Jet.OLEDB.4.0; " +
"Data Source=" + "\"" + path + "\"" + ";" +
"Jet OLEDB: System Database=" + "\"" + path2 + "\"" + ";" +
"User Id = user1; " +
"Password = pass1";


path and path2 surly are correct. "path" is the path to the database and "path2" is the path to the work group information file. The whole connection string seems to be correct, as well.

But I keep getting this exception when opening the oledb connection:

 Cannot start your application. The workgroup information file is missing or opened exclusively by another user.

Workgroup information file is not missing, that is sure. Being opened exclusively by another user doesn't make sense either, because the file is on local computer and MS Access is closed.

Answers (6)