EVENT HANDLING IN D365
Event Handler Methods in Dynamics 365 for operations is the preferred mechanism for customizations to existing objects by using event handlers to react to various events rather than overriding methods on tables, forms, and classes. In our case, we want to perform an action on the ‘ OnClicked ’ event. We want to disable an existing control on the form, by creating a new control and whenever this control is checked the existing control is disabled. · Extensions Creating purchase order form and its main data source table extensions. Adding A field in Table Extension Add a new field in the extension table named IsInvoiceable and type NoYes enum. Adding new control in form design: Create a new group and inside that group a new check box. Now copy the OnClicked event of the newly created check box · Handler class Now we need a handler class to add the changes we want. we add our lo...