P
Paul
I have a datagrid in which I am displaying a column as a checkbox. A
snippet of the aspx code where I use a template column to do this is shown
below.
I am at a loss as to how to respond to the checkbox being clicked. Any help
would be appreciated.
TIA
Paul
<asp:datagrid id="gridLocBased" style="Z-INDEX: 101; LEFT: 46px;
POSITION: absolute; TOP: 71px" runat="server" BorderWidth="3px"
BorderColor="DarkGray" BorderStyle="Double" AutoGenerateColumns="False"
HorizontalAlign="Center" Width="469px">
<AlternatingItemStyle Font-Size="X-Small"
BackColor="Cornsilk"></AlternatingItemStyle>
<ItemStyle Font-Size="X-Small" BorderWidth="3px" BorderStyle="Double"
BackColor="WhiteSmoke"></ItemStyle>
<HeaderStyle Font-Size="X-Small" Font-Bold="True"
HorizontalAlign="Center" ForeColor="Cornsilk"
BackColor="RoyalBlue"></HeaderStyle>
<Columns>
<asp:TemplateColumn HeaderText="Enabled">
<HeaderStyle Width="60px"></HeaderStyle>
<ItemStyle HorizontalAlign="Center"></ItemStyle>
<ItemTemplate>
<asp:CheckBox runat="server" ID="cbxEnabled" Checked='<%#
Convert.ToBoolean( DataBinder.Eval( Container, "DataItem.Enabled" ) ) %>'
AutoPostBack="true">
</asp:CheckBox>
</ItemTemplate>
</asp:TemplateColumn>
snippet of the aspx code where I use a template column to do this is shown
below.
I am at a loss as to how to respond to the checkbox being clicked. Any help
would be appreciated.
TIA
Paul
<asp:datagrid id="gridLocBased" style="Z-INDEX: 101; LEFT: 46px;
POSITION: absolute; TOP: 71px" runat="server" BorderWidth="3px"
BorderColor="DarkGray" BorderStyle="Double" AutoGenerateColumns="False"
HorizontalAlign="Center" Width="469px">
<AlternatingItemStyle Font-Size="X-Small"
BackColor="Cornsilk"></AlternatingItemStyle>
<ItemStyle Font-Size="X-Small" BorderWidth="3px" BorderStyle="Double"
BackColor="WhiteSmoke"></ItemStyle>
<HeaderStyle Font-Size="X-Small" Font-Bold="True"
HorizontalAlign="Center" ForeColor="Cornsilk"
BackColor="RoyalBlue"></HeaderStyle>
<Columns>
<asp:TemplateColumn HeaderText="Enabled">
<HeaderStyle Width="60px"></HeaderStyle>
<ItemStyle HorizontalAlign="Center"></ItemStyle>
<ItemTemplate>
<asp:CheckBox runat="server" ID="cbxEnabled" Checked='<%#
Convert.ToBoolean( DataBinder.Eval( Container, "DataItem.Enabled" ) ) %>'
AutoPostBack="true">
</asp:CheckBox>
</ItemTemplate>
</asp:TemplateColumn>