tags:

views:

4984

answers:

3

I have searched for various techniques on how to read/write dBase III (dbf) files using OLEDB or ODBC with C#/.NET. I have tried almost all of the tecniques posted, but without success. Can someone point me in the right direction?

Thanks for your time.

+2  A: 

FoxPro 2.0 files were exactly the same as dBase III files with an extra bit for any field that was of type "memo" (not sure the exact name, it's been a while). That means that if you just use a FoxPro 2.x method for accessing the files, it should work.

Kearns
+3  A: 

Something like ... ?

 ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;" & _
"Data Source=e:\My Documents\dBase;Extended Properties=dBase III"
Dim dBaseConnection As New System.Data.OleDb.OleDbConnection(ConnectionString )
dBaseConnection.Open()

From: http://bytes.com/forum/thread112085.html

Remou
You can also create an ODBC DSN for the connection in Control Panel and then connect to that in your code.
runako
A: 

This is a nice aproach, i didn't tested, but i will soon...

http://www.c-sharpcorner.com/uploadfile/rfederico/xbaseenginerfv12022005011623am/xbaseenginerfv.aspx

Regards,

Mauricio Atanache