Nov 25, 2005 01:32 AM|PatrickRR|LINK
Well now I know. The return values using the Data Access Blocks is due to the fact you can call the methods using values or SQL Params. If you want a return value you have to pass the parms and not By
Value to SQLHELPER.
If you search on RETURN VALUES USING DATA ACCESS BLOCK you will soon see how many people are banging thier heads against the wall.
Finally after a lot of reading and testing I have it.
CREATE A PARAM Array
Dim SQLp(1) As SqlParameter
'My proc has two params Key, and Output
SQLp(0) = New SqlParameter("@CartID", strCartID)
SQLp(1) = New SqlParameter("@ItemsTotal", SqlDbType.Money)
SQLp(1).Direction = ParameterDirection.Output
'Forget about ReturnValue = SqlHelper. (THIS DOES NOT WORK!)
Guess what? The parm is returned back on the same param that was passed into the DAAB
Dim sCartTotal As