I am accessing a SQL2000 Db using VB6 front end. I need to be able to return a ADODB recordset in Sub_1, and then pass each record in that rs to another routine Sub_Validate
eg
Thanks
eg
Code:
Sub_1()
' open the recordset
set rs = new adodb.recordset
rs.open "select * from SQLtable1", DE1,cnn1
if rs.recordcount > 0 then
rs.movefirst
do
validate (liError) 'Pass the first rec to sub Validate
rs.movenext
reccount = recount + 1
loop until rs.eof
end sub
Sub_validate()
If rs!Field1<> 999 or rs!field1 <> -1 then
'write error log stuff
etc with remaining fields in each record
end if