DataSet ds = BindDatas(); if (ds != null && ds.Tables.Count > 0 && ds.Tables[0].Rows.Count > 0)
{ DataPager1.SetPageProperties(0, 20, true);
}
if (ds == null || ds.Tables[0].Rows.Count <= 0)
{
this.ClientScript.RegisterStartupScript(this.GetType(), "提示", "<script>alert('没有符合条件的数据!')</script>"); }
当第一次搜索时,ds不为空list显示数据,接下来再搜索一次,假如ds=null 会弹出“没有符合条件的数据!”但页面却没有清空,有什么好方法?
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货