当ListView控件在后台绑定数据源时,即不用SqlDataSource做数据源,
再利用DataPager分页的时候,要调用一下方法:
   
    /// <summary>
    /// ListView分页出发事件
    /// </summary>
    /// <param name="sender"></param>
    /// <param name="e"></param>
    protected void ListView1_PagePropertiesChanged(object sender, EventArgs e)
    {
        DataPager1.SetPageProperties(list_DataPager.StartRowIndex, 16, true);
        Bind();  //再次调用自己定义的绑定数据源方法
    }

相关文章:

  • 2021-11-13
  • 2022-12-23
  • 2022-12-23
  • 2022-03-02
  • 2022-02-23
猜你喜欢
  • 2021-10-06
  • 2022-02-17
  • 2022-12-23
  • 2021-05-25
  • 2021-11-22
  • 2021-10-26
相关资源
相似解决方案