|
From: <alb...@ti...> - 2007-08-29 16:14:26
|
Hi,
using a version 2.1.0 RC-1 i have
some problem with a Dispose
method.
Why throw this exception ?
"Invalid attempt of read when
the reader is closed."
I create a FbCommand in this mode:
private
static object executeQuery(DbConnection p_conn, string p_sql, hashtable
p_params)
{
DbCommand oc = null;
object res = DBNull.Value;
if (p_conn.getType().Equals(typeOf(FbConnection)) ){
oc =
new FbCommand(p_sql, (FbConnection)p_conn);
... assign params
res = oc.ExecuteReader();
}
...other
database connection type, such as Oracle, Sql Server...
oc.
Dispose();
return res;
}
I use the Dispose() method
because I see the memory of the
main process increase in exponential
mode.
Sorry for my bad english.
Thanks.
Alberto
|