i am using jquery for enabling and disabling a button
$(function () {
$('.CSSCheck').click(function () {
if ($("[id$='Chkbox']:checked").length > 0) {
$("#<%=Button1.ClientID %>").removeAttr('disabled');
}
else {
$("#<%=Button1.ClientID %>").attr('disabled', 'disabled');
}
});
});
on code behind i am adding a css to datalist image button on Select_Command
DataListItemCollection xxx = datalist1.Items;
int index = id;
int count = 0;
foreach (DataListItem x in xxx )
{
if (count == index)
{
(x.FindControl("btn1") as ImageButton).BorderColor = System.Drawing.Color.Blue;
(x.FindControl("btn1") as ImageButton).BorderWidth = 1;
}
}
how to remove this css using the same jquery?