存储过程
create proc test4
@res varchar(10) output
as
select @res=count(*) from Ship_TUser_Info
go
cs文件:
SqlParameter[] paras = new SqlParameter[] { new SqlParameter("@res", SqlDbType.Int) };
paras[0].Direction = ParameterDirection.Output;
SqlHelper.ExecuteNonQuery(SqlHelper.ConnectionStringLocalTransaction, CommandType.StoredProcedure, "test4", paras);
Response.Write(paras[0].Value.ToString());