locked
Problem with Access db connectionstring on DataContext class RRS feed

  • Question

  • Hi!

    code below throws an ArgumentException with message: "Keyword not supported: 'provider'."

    string connectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data  Source=D:\\people.accdb";
    //
    DataContext db = new DataContext(connectionString);
    Table<Users> users = db.GetTable<Users>();
    var UsersQuery = from p in users
                     select p;
    foreach (var person in UsersQuery)
        Console.WriteLine("FIRSTNAME: {0} LASTNAME: {1}", person.FIRSTNAME, person.LASTNAME);
    //
    
    
    What should i do to fix this?

    Tuesday, March 26, 2013 12:40 PM

Answers

All replies