Hi Mahesh,
How to insert checkbox field in the gridview?
Regards,
Geetha
Hi Mahesh,
How to insert checkbox field in the gridview?
Regards,
Geetha
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Geetha SeetharamaiahPosted Oct 22, 2008, 4:49 AM
Blocked AccountPosted Oct 22, 2008, 3:14 AM
Hi,
you can put checkbox field in the gridview by using template field as follows:
<
asp:TemplateField HeaderText="Active"> <ItemStyle Width="25px" HorizontalAlign="Center" VerticalAlign="Middle" /> <ItemTemplate><asp:CheckBox ID="CheckBoxActive" runat="server" Checked='<%# DataBinder.Eval(Container.DataItem,"Active") %>' />
ItemTemplate> asp:TemplateField>Happy Coding!!