The calculated fields feature in Microsoft Dynamics 365 Customer Engagement (D365 CE) is a powerful tool to allow you to automatically calculate a value based on user-provided or system-driven data.
For example, let us say on an Opportunity you want to calculate the difference between the budgeted amount and the actual amount generated from the Opportunity Product lines. Calculated fields will let you do that. Not only can calculated fields do simple calculations, they also can utilize if/then conditions and more advanced formulas such as date/time. You can set a calculated field to find the difference between two date fields in Days, Months, Hours, Years, and Minutes.
Using our above example, we want to calculate the difference between the budget and actuals, but let us say we want to make that value 0 if our opportunity is lost. In our formula for the calculation, we can add an if condition that says if the opportunity is lost, set our calculation to 0.
However, there are some considerations to take into place when using a calculated field. The value in a calculated field cannot be manually overridden. The field by default will be read only, and only the calculation can be populated. The fields involved in the calculation also must have values present to calculate a result. For example, you want to add up three cost fields, if two of those costs’ fields contain a number and one does not, the calculation will not run. So, make sure all the fields are either populated by a user or the system. Calculated fields can be created on field types of single line of text, option set, two option, whole number, decimal number, currency, and Date and Time.
Now I can add this field to my form and watch the calculation run!
Have any questions about adding calculated fields in D365 CE or regarding D365 CE in general? Please contact us at any time!
This publication contains general information only and Sikich is not, by means of this publication, rendering accounting, business, financial, investment, legal, tax, or any other professional advice or services. This publication is not a substitute for such professional advice or services, nor should you use it as a basis for any decision, action or omission that may affect you or your business. Before making any decision, taking any action or omitting an action that may affect you or your business, you should consult a qualified professional advisor. In addition, this publication may contain certain content generated by an artificial intelligence (AI) language model. You acknowledge that Sikich shall not be responsible for any loss sustained by you or any person who relies on this publication.