string sql = "showpage ";
SqlParameter[] par = new SqlParameter[8];
par[0] = new SqlParameter( "@sqlstring ", SqlDbType.NVarChar, 2000);
par[0].Value = "* from luo_payto ";
par[1] = new SqlParameter( "@keyid ", SqlDbType.NVarChar, 300);
par[1].Value = "id ";
par[2] = new SqlParameter( "@pagesize ", SqlDbType.Int, 4);
par[2].Value = 20;
par[3] = new SqlParameter( "@curpage ", SqlDbType.Int, 4);
par[3].Value = curpage;
par[4] = new SqlParameter( "@pagecount ", SqlDbType.Int, 4); //总页数
par[4].Direction = ParameterDirection.Output;
par[5] = new SqlParameter( "@RecordCount ", SqlDbType.Int, 4); //总记录
par[5].Direction = ParameterDirection.Output;
par[6] = new SqlParameter( "@strcon ", SqlDbType.NVarChar, 200);
par[6].Value = "luo_payto ";
par[7] = new SqlParameter( "@sort ", SqlDbType.NVarChar, 50);
par[7].Value = "desc ";
SqlDataReader dr= SqlHelper.ExecuteReader(SqlHelper.sqlstring,CommandType.StoredProcedure, sql, par);
int totalpage = Convert.ToInt32(par[4].Value);
int recordcount = Convert.ToInt32(par[5].Value);
DataList1.DataSource = dr;
DataList1.DataBind();
什么为调用SqlHelper.ExecuteReader后 存储过程的output返回值取不到呢/?
急啊~~
哪位大哥帮帮忙~~
------解决方案--------------------------------------------------------
SQL Helper Bug 换一个方法重载可能就好了!好久不用SQLHelper,不能给你更多帮助了