The calculation field is an advanced feature in the form builder, which can be used in a variety of ways for any form template.


The general concept for a basic calculation is the object name of the target field is in square brackets [ XXXX ], then the method of operation (+, -, * etc..), and then the secondary object name, again, in square brackets.

For a basic calculation adding two different fields together, this would be in the following structure:


[objectName1] + [objectName2]


This would appear as follows in the form builder using a calculation field:



Calculations follow the BEDMAS (Brackets, Exponents, Division/Multiplication, Addition/Subtraction) order of completion.


This means that brackets can be used to group the ordering. We can also include static numbers as part of the calculation. 


Combining these options, we can multiply our example by 2, which would update the calculation to the following structure - ([amountOne] + [amountTwo]) * 2


The following are example scenarios which explain the different ways a calculation field can be utilised in a form template:


Time Calculations

Age Calculations

Point / Percentage Scoring

Pricing

Counting


For more information on Object Names, refer to the follow article - What is an Object Name?