Re: Returning recordset from a function and using EOF
- From: "bob m" <leav@xxxxx>
- Date: Thu, 9 Nov 2006 12:43:00 -0500
eof is a propert of the RS.
example....
Do While Not RS.EOF
'display record data
RS.MoveNext
Loop
<sherri.wheeler@xxxxxxxxx> wrote in message
news:1163093864.919528.249950@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi,
I have been all over the web looking for a definitive answer to this
question. I want to have a function which grabs a record set, and
returns it. Then, after my function call, I want to use something like
EOF or GetRows() to cycle through the record set. But no matter what I
try, I get the following error:
Object doesn't support this property or method: 'currentRow.EOF'
-----------------
Code returning set from function:
<snip>
rs.Open cmd, , adOpenStatic, adLockReadOnly
Set cmd.ActiveConnection = Nothing
Set cmd = Nothing
set rs.ActiveConnection = Nothing
oConn.Close
Set oConn = Nothing
getReportLogRow = rs ' This is the return statement
End Function
----------
Code using the returned recordset:
<snip>
Set currentRow = CreateObject("ADODB.Recordset")
Set currentRow = getReportLogRow(sessID)
if(currentRow.EOF)then
<snip>
---------------------
If I can solve this... I'm gonna publish the solution all over the
place because I can't be the only one ripping out their hair over this.
Why does vbscript-asp make using functions such a pain? ;)
Thanks for any help!
.
- References:
- Returning recordset from a function and using EOF
- From: sherri . wheeler
- Returning recordset from a function and using EOF
- Prev by Date: Re: Take ownership of multiple folders?
- Next by Date: Re: Select control DHTML
- Previous by thread: Re: Returning recordset from a function and using EOF
- Next by thread: Re: Returning recordset from a function and using EOF
- Index(es):
Relevant Pages
|