ENABLE DISABLED RADIOBUTTONLIST WITH JQUERY

Chintoo Semi

Total Post:135

Points:947
Posted by  Chintoo Semi
 1092  View(s)
Ratings:
Rate this:

I have a radiobuttonlist initially disabled (Enabled="false"). I want to enable it on a button click. The jQuery line that would enable the radiobuttonlist is as follows:

 

$("#<%=MyRadioButtonList.ClientID%>").prop("disabled", false);

But it does not work. What I noticed is that ASP.NET encloses the input tag with which, if I understand correctly, prevents the javascript code from enabling the list.

What would you suggest?

  1. Kamlakar Singh

    Post:194

    Points:1396
    Re: Enable disabled Radiobuttonlist with jQuery

    You can simply try like this

    $("#<%=MyRadioButtonList.ClientID %>").find('input').prop('disabled', false);

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!