[摘要]Int32.Parse(gotoPage.Text) <= 0) Response.Write("<script>alert('页码范围越界!')...
Int32.Parse(gotoPage.Text) <= 0)
Response.Write("<script>alert('页码范围越界!');location.href='WebForm8.aspx'</script>");
else
{
int InputPage = Int32.Parse(gotoPage.Text.ToString()) - 1;//转换用户输入值保存在int型
InputPage变量中
ViewState["PageIndex"] = InputPage;//写入InputPage值到ViewState["PageIndex"]中
TDataBind();//调用数据绑定函数TDataBind()再次进行数据绑定运算
}
}
//捕获由用户输入不正确数据类型时造成的异常
catch(Exception exp)
{
Response.Write("<script>alert('"+exp.Message+"');location.href='WebForm8.aspx'</script>");
}
}
}
}
关键词:asp.net(C#)海量数据表高效率分页算法