How to check whether a text box is read-only or not?

 Posted by vishalneeraj-24503 on 12/27/2013 | Category: JavaScript Interview questions | Views: 1447 | Points: 40
Answer:

var is_readonly = document.getElementById('<%=txt_description.ClientID%>').readOnly;


<asp:TextBox ID="txt_description" runat="server" TextMode="MultiLine" ReadOnly="true"></asp:TextBox>


Output will be True.


Asked In: Many Interviews | Alert Moderator 

Comments or Responses

Login to post response