Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Which Provider must i choose? 1

Status
Not open for further replies.

mxo

Programmer
May 20, 2005
51
ZA
Hi

I just installed Microsoft office 2007 but when i want to create data connection in vb.net using a wizard from access database i get the following: an error in initializing provider. Unrecognized database format.

your help will be highly appreciated

mxo


 
VS 2003 came out before Access 2007. I think this is your problem as far as the Wizards.

To get a good connection string so that you can do this via code, go to
I hope this helps.



Ron Repp

If gray hair is a sign of wisdom, then I'm a genius.
 
Where are you creating the connection in ?

Visual Studio?
Access 97/2003/2007?
Word 2007?

If in Visual Studio, are you creating the connection by going through a wizard for a control or for the project?

-The answer to your problem may not be the answer to your question.
 

You can use the following Connection String for Microsoft Access 2007 in ADO.NET or using Sysem.Data.OleDb namespace.

When Access 2007 database is without security:
Code:
[b]Provider=Microsoft.ACE.OLEDB.12.0;Data Source=[i][COLOR=pink]C:\MyDataFiles\MyDatabaseFile.accdb[/color][/i];Persist Security Info=False[/b]

When Access 2007 databse is password protected:
Code:
[b]Provider=Microsoft.ACE.OLEDB.12.0;Data Source=[i][COLOR=pink]C:\MyDataFiles\MyDatabaseFile.accdb[/color][/i];Jet OLEDB:Database Password=[i][COLOR=pink]MyDatabasePassword[/color][/i][/b]

Hope it helps.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top