I am trying to get the total amount of records that my stored procedure returns
using the SP
CREATE PROCEDURE [dbo].NewSelectCommand
(
@catID int
)
AS
SET NOCOUNT ON;
SELECT catID, title, size, type, printon, inkType, item, imageUrl, transferID FROM TransferDesigns WHERE (catID = @catID)
RETURN @@ROWCOUNTThen on the aspx.cs file
KraftDataContext dataContext = new KraftDataContext();
var catNames = dataContext.NewSelectCommand(catID);
DataList1.DataSource = catNames;
DataList1.DataBind();
Now when I debug the breakpoint before DataBind there is a ResultValue or ReturnValue with the correct amount under NewSelectCommandResults in it but I cant seem to get it there is ISingleResult Well anyway I need the total number of returned records so I can build the PageSize