How to throw validation notification on Fields residing in Form Header
Hi All,
Have you tried setting Field level notification on the Form Header of the Record?
Let’s consider an example,
We have an Estimated Revenue field which should never be set a $0.00. Therefore, we must throw a notification error based on this validation.
The formula for setting field level notification is generalized as follows,
formContext.getControl(fieldname).setNotification(errormessage);
Now let’s see how this general formula changes based on the field’s location set on the Form.
- If Field is located on the Form
Formula will be:
formContext.getControl(fieldname).setNotification(errormessage);
- If Field is located on the Form Header
Formula will be:
formContext.getControl(“header_”+fieldname).setNotification(errormessage);
- If Field is located on the Form Business Process Flow (BPF)
Formula will be:
formContext.getControl(“header_process_”+fieldname).setNotification(errormessage);
Hope this helps!!
Related posts:
User Adoption Strategy for Dynamics 365 Implementation Success
Creating an Application User for Dynamics 365 CRM in the Azure Portal and When to Use It
Customizing the Opportunity Close Dialog Box in Dynamics 365 CRM
The Importance of Physical Tracking and Negative Inventory Control to Prevent Stock Outs in D365 F&O