if (e.Item.ItemType == ListItemType.Item || e.Item.ItemType == ListItemType.AlternatingItem)
            {
                    string id = ((DataRowView)e.Item.DataItem)["ID"].ToString();
                           }

 

 

 

 ((DataRowView)e.Item.DataItem)只在itemcreate和itemdatabind事件中不为null

 

找到HeaderTemplate里的控件:

this.rptBook.Controls[0].FindControl("ckbCheckAll")

相关文章:

  • 2021-06-01
  • 2022-12-23
  • 2022-12-23
  • 2021-07-02
  • 2021-07-24
  • 2021-07-14
  • 2021-07-11
猜你喜欢
  • 2021-06-28
  • 2022-01-27
  • 2021-11-07
相关资源
相似解决方案