All am disabling all the fields on the form. Fields except the check boxes are disabling.
Can you help why check boxes are not disabled.
The code is :
function disableFormFields(onOff) {
Xrm.Page.ui.controls.forEach(function (control, index) {
if (doesControlHaveAttribute(control)) {
control.setDisabled(onOff);
}
});
}
function doesControlHaveAttribute(control) {
var controlType = control.getControlType();
return controlType != "iframe" && controlType != "webresource" && controlType != "subgrid";
}
Why this code is not working fine in CRM 2013. This is working fine in CRM 2011.
Thanks!!!!