ConnectionString with Microsoft Jet OLEDB

  • Thread starter Thread starter Gianluca_Venezia
  • Start date Start date
G

Gianluca_Venezia

Hi all,
I'm approaching at .Net for make up a site but I have a problem with
web.config. I'm trying to use an *.mdb file as db, and I'd think to
use this:
<add key="ConnectionString" value="Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=\db\db2.mdb" />

but server response me so:
ArgumentException: key word 'provider' not supported

and I'm finding no info about use *.mdb file...

Where I can find some info about?

Thanks
Gianluca
 
You should be specifying the full physical path to the database, not a
relative path.


Dim con as New Ole.OleDbConnection("Provider=Microsoft.JET.OLEDB.4.0;Data
Source=C:\...."
 
What kind of Connection object are you using? You need to use a
OLEDBConnection (and not a SQLConnection) object.

--

HTH

Éric Moreau, MCSD, Visual Developer - Visual Basic MVP
Conseiller Principal / Senior Consultant
Concept S2i inc.(www.s2i.com)
 
Hi all,
<add key="ConnectionString" value="Provider=Microsoft.Jet.OLEDB.4.0;
Data Source=\db\db2.mdb" />

Check this link:

www.connectionstrings.com
--
Chris

dunawayc[AT]sbcglobal_lunchmeat_[DOT]net

To send me an E-mail, remove the "[", "]", underscores ,lunchmeat, and
replace certain words in my E-Mail address.
 
Back
Top