I have a lot of fields that are controlled onChange. I know I can register that in the form, however since I have more than 40 fields, I tried to use the following function and I call the function onLoad on the form, but I am not getting the result. Thank you for the help!
function setEventOnChange() {
Xrm.Page.getAttribute(new_account).addOnChange(accountOnChange);
Xrm.Page.getAttribute(new_contact).addOnChange(accountOnChange);
}