"Naveen K Kohli" <naveenkohli@hotmail.com> wrote in message news:<uDh3MJKQDHA.2476@TK2MSFTNGP10.phx.gbl>...
> DataReader is not exactly but sort of a connected recordset. Meaning when it
> starts reading from DB, it does not know records before hand. It reads them
> one at a time and streams them to the caller. It does not keep any thing in
> memory. Once you have read one record it forgets about it. And once you have
> read all records. You can't go back. After closing the connection you can't
> use the same data reader unless you open a new connection for it.
Thanks.

Can I do smt. like in code below?

Function whatever (...) as sqldatareader
...
mydatareader = blabla.executeReader
conn.close()
return mydatareader
End function

Ante