1

I have a simple requirement of changing label of a checkbox on click within ASP.net

Here is the code:-

<asp:CheckBoxList runat="server"  ID="myChks" RepeatColumns="1" CssClass="checkbox">
    <asp:ListItem Text="Some Text" Value="myCheckBox" Selected="False"></asp:ListItem>
</asp:CheckBoxList>

What I am hoping to do is to change "Some Text" to "This is a long text <br /> This is a long description of some text", when this checkbox is clicked.

What I am trying to find out is, how can get an element of this checkbox in JQuery when there's no ID. The listitem is the first child though of the checkbox.

Please advise.

Thanks.

Steve
  • 2,546
  • 8
  • 49
  • 94
  • possible duplicate of [Accessing control Client Name and not Id in ASP.NET](http://stackoverflow.com/questions/5763557/accessing-control-client-name-and-not-id-in-asp-net) – terary Jan 21 '15 at 05:33

0 Answers0