Can anyone please provide the C# coding to add checkbox control at the Header of DatagridviewCheckBoxColumn.
Convert the Check Box Column to a template field. Then add the Check box to the header template.
I think WarithNath is right. Here is a suggestion code.
<asp:TemplateField>
<EditItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server" />
</EditItemTemplate>
<ItemTemplate>
<asp:CheckBox ID="CheckBox1" runat="server" />
</ItemTemplate>
<HeaderTemplate>
<asp:CheckBox ID="CheckBoxToSelectAll" runat="server" />
</HeaderTemplate>
</asp:TemplateField>
Hope it works!
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.