JimDel
JimDel

Reputation: 4359

How can I add an Access DB to my C# project when it requires an MDW file too?

I want to use an Access database file in my C# project. When I add it as a new Data Source all goes well until I try to test the connection. Then I get the message:

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

The file is password protected and an MDW file is used. So how can I add the file as a data source and use the workgroup info file as well?

Thanks

Upvotes: 1

Views: 1343

Answers (1)

D'Arcy Rittich
D'Arcy Rittich

Reputation: 171351

Here is an example connection string specifying where the .MDW file is located:

Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\mydatabase.mdb;
    Jet OLEDB:System Database=system.mdw;User ID=myUsername;Password=myPassword;

Upvotes: 5

Related Questions