Repost - Return recordset as integer

R

Rajat

Hi,

I have a stored procedure that returns a one-record, one-
field recordset off a SELECT statement.

I need to be able to return this value from the stored
procedure as an integer.

In VBA, I would have done the following:

*************************************************
Set rs = db.OpenRecordset(strSQL, dbOpenForwardOnly,
dbReadOnly)
If rs.RecordCount = 0 Then
intLaptopCount = 0
Else
intLaptopCount = rs![LaptopCount]
End If
***************************************************

Thanks,

Rajat
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top