Hello,
I have disabled checkboxes within the rad grid on the server side and I am unable to enable them via javascipt. How can this be achieved?
I use this code to enable/disable checkboxes via JavaScript
This code above works just fine until i disable the checkboxes on the server:
Then when I try to run the javascript code it puts the checkboxes in a wierd state. I have attached a screen shot. How do I enable these checkboxes again via javascript?
I have disabled checkboxes within the rad grid on the server side and I am unable to enable them via javascipt. How can this be achieved?
I use this code to enable/disable checkboxes via JavaScript
function SelectDependentRoles(checked, readerCheckbox, dropboxCheckbox) { if (checked) { readerCheckbox.checked = checked; readerCheckbox.disabled = true; dropboxCheckbox.checked = checked; dropboxCheckbox.disabled = true; } else { readerCheckbox.checked = checked; readerCheckbox.disabled = false; dropboxCheckbox.checked = checked; dropboxCheckbox.disabled = false; } }This code above works just fine until i disable the checkboxes on the server:
private void EnableCheckboxes() { foreach (GridDataItem row in dgLoginRequest.MasterTableView.Items) { var chbxReader = (CheckBox)row.FindControl("chbxReader"); var chbxRKDropbox = (CheckBox)row.FindControl("chbxRKDropbox"); var chbxShare = (CheckBox)row.FindControl("chbxShare"); chbxReader.Enabled = !chbxShare.Checked; chbxRKDropbox.Enabled = !chbxShare.Checked; } }Then when I try to run the javascript code it puts the checkboxes in a wierd state. I have attached a screen shot. How do I enable these checkboxes again via javascript?