J
Joe
Hi all.
I'm trying to open a dbf file which appears to be FoxPro. I've tried using
the OLE and ODBC classes but I'm not having any luck.
I keep getting an exception: "The Microsoft Jet database engine could not
find the object 'EQR_TRANSACTION_200803'. Make sure the object exists and
that you spell its name and the path name correctly."
Here is the ODBC code:
try
{
string connString = @"DBQ=C:\Test;Driver={Microsoft dBase Driver (*.dbf)};
DriverId=277";
OdbcConnection conn = new OdbcConnection(connString);
OdbcDataAdapter da = new OdbcDataAdapter("select * from
EQR_TRANSACTION_200803", conn);
DataTable table = new DataTable("table");
da.Fill(table);
dataGridView1.DataSource = table;
}
catch (Exception e)
{
MessageBox.Show(e.Message);
}
Any ideas?
Thanks,
Joe
I'm trying to open a dbf file which appears to be FoxPro. I've tried using
the OLE and ODBC classes but I'm not having any luck.
I keep getting an exception: "The Microsoft Jet database engine could not
find the object 'EQR_TRANSACTION_200803'. Make sure the object exists and
that you spell its name and the path name correctly."
Here is the ODBC code:
try
{
string connString = @"DBQ=C:\Test;Driver={Microsoft dBase Driver (*.dbf)};
DriverId=277";
OdbcConnection conn = new OdbcConnection(connString);
OdbcDataAdapter da = new OdbcDataAdapter("select * from
EQR_TRANSACTION_200803", conn);
DataTable table = new DataTable("table");
da.Fill(table);
dataGridView1.DataSource = table;
}
catch (Exception e)
{
MessageBox.Show(e.Message);
}
Any ideas?
Thanks,
Joe