Posts

Showing posts from January, 2023

SETSUBMITMODE IN DYNAMICS 365 JAVASCRIPT

Image
In Dynamics 365, there are some scenarios where you want to always submit or never submit the value of a column into the database. To do this, you have to use the JavaScript method setSubmitMode that will control whether the data for a column is submitted when a record is created or saved. In case you have a column that you are not interest to capture its data, use the never parameter for the setSubmitMode method. While, if you want to force a column value to be submitted whether it has changed or not, use the always parameter for the setSubmitMode method. Use one of the below three options for the setSubmitMode function as per the below. always : The data is always sent with a create/save event and can be captured within the entity attributes in a plugin function setSubmitModeField(context) { var formCont

ACCESS FIELDS OF QUICK VIEW FORM THROUGH JAVASCRIPT IN DYNAMICS 365

Image
As known, quick view controls are associated to lookup fields that are included in a form and they are added to display specific information about the selected record in the lookup field. This will increase user experience where the users do not need to navigate to a different record to see the information needed. However, you might have requirements where you want to check a field value of the quick view form control in order to apply specific behavior on the main form. In this post, we will see how to access Quick View Form fields through JavaScript in Dynamics 365 . For the sake of this post, we will work with a contact quick view form control on the account form. Based on the primary contact Relationship Type field, a specific section on the account form will be displayed. Relationship Type field of the contact = Employee => Employee