K
Keith Bozek
For demonstration purposes, I am trying to open a QIF file via the
OleDbConnection->OleDbCommand->OleDbDataReader. If I maintain the QIF
extension, I encounter the Database or object is read-only error when
I atttempt to execute the DataReader against a QIF file. However, if
I use the .txt extension the code is happy.
I have been looking around but just cannot remember how to set
extended properties so that it knows about a QIF file.
Keith
ERROR:
An exception occurred. Message: Cannot update. Database or object is
read-only.
ErrorCode: -2147217911
Source: Microsoft JET Database Engine
CODE BLOCK:
OleDbConnection conn = new OleDbConnection(
"Provider=Microsoft.Jet.OLEDB.4.0;" +
"Data Source=" + strPath + ";" +
"Extended
Properties=\"text;HDR=NO;FMT=Delimited\"");
conn.Open();
OleDbCommand SearchCmd = new OleDbCommand ("SELECT * FROM
Quicken.qif", conn);
OleDbDataReader Reader =
SearchCmd.ExecuteReader(CommandBehavior.Default);
OleDbConnection->OleDbCommand->OleDbDataReader. If I maintain the QIF
extension, I encounter the Database or object is read-only error when
I atttempt to execute the DataReader against a QIF file. However, if
I use the .txt extension the code is happy.
I have been looking around but just cannot remember how to set
extended properties so that it knows about a QIF file.
Keith
ERROR:
An exception occurred. Message: Cannot update. Database or object is
read-only.
ErrorCode: -2147217911
Source: Microsoft JET Database Engine
CODE BLOCK:
OleDbConnection conn = new OleDbConnection(
"Provider=Microsoft.Jet.OLEDB.4.0;" +
"Data Source=" + strPath + ";" +
"Extended
Properties=\"text;HDR=NO;FMT=Delimited\"");
conn.Open();
OleDbCommand SearchCmd = new OleDbCommand ("SELECT * FROM
Quicken.qif", conn);
OleDbDataReader Reader =
SearchCmd.ExecuteReader(CommandBehavior.Default);