Sunday, August 2, 2009

How can i make a checkbox readonly in c#.net?

Disable it by setting its Enabled property to false





%26lt;asp:CheckBox id="chkMyCheckBox" runat="server" Enabled="false" Text="You cannot check Me!" %26gt;%26lt;/asp:CheckBox%26gt;





You might also want to do that programatically





chkMyCheckBox.Enabled = false;


No comments:

Post a Comment