Hiding a control in a TemplateField in a GridView
Posted on 2011-09-29
I have the following Template field in a GridView:
<asp:Label runat="server" Text='<%#Eval("PIP") %>'></asp:Label>
<asp:CheckBox ID="chkPIP" runat="server" />
On some rows, I do not want the CheckBox to be visible or at least not checkable.
I am trying to use the RowDataBound event, but I can't figure out how to reference my checkbox control.
Can anyone show me how?