locked
Connection string to Access Database RRS feed

  • Question

  • Hi everyone. My query is not the straightforward connection to MS Access. I am using a third application that places all data in an Access database BUT recently they changed the database so that it doesn't end in '.mdb', instead in another suffix: '.accdb'. The database is still an Access database but I cannot connect to it using the connection strings:

    connection.open "Driver=Microsoft Access Driver (*.accdb);DBQ=c:\Database\DatabaseName.accdb"  OR

    connection.open "Driver=Microsoft Access Driver (*.mdb);DBQ=c:\Database\DatabaseName.accdb"

    Previously I was able to use the second connection when the database name ended in '.mdb' (DatabaseName.mdb).

     

    Anyboby able to help? It would be greatly appreciated.

     

    Regards

    Tim Christopher

    Saturday, September 10, 2011 9:38 AM

Answers

  • the database has become an Access 2007 database, so the connectionsting must change as here:

    http://www.connectionstrings.com/access-2007

     


    please, mark this as answer if it is THE answer
    ----------------
    Diego Cattaruzza
    Microsoft MVP - Visual Basic: Development
    blog: http://community.visual-basic.it/Diego
    web site: http://www.visual-basic.it
    • Proposed as answer by Carmelo La Monica Saturday, September 10, 2011 1:30 PM
    • Marked as answer by Mike Feng Sunday, September 18, 2011 7:11 AM
    Saturday, September 10, 2011 9:58 AM