When a 'Update' is clicked the row shows the Edititem mode.
I have a check box that when it is 'clicked' I want the other fields to dissapear/become read-only.
How can this be done client or server side?
My best guess is for server side I have something like this below.. but then in the event how do I get access 开发者_如何转开发to those items in edit mode and change them ?
<EditItemTemplate>
<asp:CheckBox ID="cbNR" runat="server" AutoPostBack="True"
OnCheckedChanged="cbNR_Clicked"
Checked='<%# Boolean.Parse(Eval("NR").ToString()) %>' />
</EditItemTemplate>
This would be pretty simple using jQuery. Code to hide the other cells when checkbox is checked:
jQuery(function() {
$("input[id*='cbNR']").click(function() {
$(this).parents("td").siblings().toggle();
});
});
精彩评论