I have the following query:
create proc [dbo].[DeleteParts]
@TransNo nvarchar (6), @fpart nvarchar(25)
AS
DECLARE @Returns BIT
SET @Returns =
ExecuteNonQuery
will return the number of rows affected but NOT data (that's why its a non-query). So it won't bring anything back.
This might be useful to read:
http://www.dreamincode.net/forums/topic/76434-executenonquery-with-output-parameters/
You'll need to use a different mechanism to get your data out - how about ExecuteReader with an output parameter?