我有一个允许分页的gridview。但是当我单击第二页时,gridview 消失了,这里是 c# 代码:
protected void GridView1_PageIndexChanging(object sender, GridViewPageEventArgs e)
{
GridView1.PageIndex = e.NewPageIndex;
OdbcDataAdapter adpState = new OdbcDataAdapter("SELECT CALL_NO,TDATE,
ID_NO,NAME,CONTACT,DEPARTMENT,ISSUE,STATUS FROM TBL_ITHELPDESK
WHERE (STATUS IS NULL OR STATUS <> 'CLOSED') AND TDATE= TO_DATE('" +
txtDate.Text.ToString().Trim() + "','MM-DD-YYYY')", con1);
DataSet ds = new DataSet();
adpState.Fill(ds);
GridView1.DataSource = ds;
GridView1.DataBind();
}
谁能帮忙找出我哪里出错了