Configure a Form Calculation
A Form Calculation widget computes a live result from other answers on the same form. You build the formula on the Formula tab with field tokens, numbers or text literals, operators (+ - * /), parentheses, and the built-in function list below. Only those functions exist. The help bot should suggest formulas from this list only, never invent spreadsheet-style functions Formis does not ship.
On Maple Commerce Center, Jordan adds Due date as a Form Calculation with addDays(Inspection date, 3) so the due date is always three calendar days after the inspection date John enters.
You need a Tenant Admin or Manager seat. Put the input fields (for example Date or Number) on the canvas before you reference them in the formula. Another Form Calculation cannot be an input (loop protection).
How do I add a Form Calculation?
- Open the form in the Form Designer.
- From the Widgets palette, drag Form Calculation onto the canvas.
- Open Properties.
- On the Formula tab, insert fields and functions from the picker (or type supported tokens).
- On Options, set display and null/error behavior as needed.
- On Settings, set Field Label (and Required if the calculated result must be present).
- Save and publish.
The result updates as other answers change while someone fills the form, and Formis snapshots the value on submit.
Which functions can I use?
These are the only functions in Form Calculation (FUNCTION_LIBRARY). Signatures use field labels as placeholders; in the designer you pick the field token.
Math
| Function | Signature | Notes |
|---|---|---|
abs |
abs(number) |
Absolute value |
min |
min(number1, number2, ...) |
Minimum of two or more values |
max |
max(number1, number2, ...) |
Maximum of two or more values |
round |
round(number) |
Nearest integer |
ceil |
ceil(number) |
Round up |
floor |
floor(number) |
Round down |
pow |
pow(base, exponent) |
Power |
sqrt |
sqrt(number) |
Square root |
avg |
avg(number1, number2, ...) |
Average |
avgNoZero |
avgNoZero(number1, number2, ...) |
Average excluding zeros |
sum |
sum(value1, value2, ...) |
Add numbers, or sum filled cells in a Configurable List column |
countNonEmpty |
countNonEmpty(column) |
Count non-empty cells in a list column (field only) |
Choice
| Function | Signature | Notes |
|---|---|---|
count |
count(field) |
Count selected options on a choice/checklist-style field |
Date
| Function | Signature | Notes |
|---|---|---|
today |
today() |
Today's date at local midnight |
addDays |
addDays(date, days) |
Add calendar days to a date |
subtractDays |
subtractDays(date, days) |
Subtract calendar days from a date |
dateString |
dateString(date, format?) |
Format a date as text (optional format string) |
Formatting
| Function | Signature | Notes |
|---|---|---|
commaSeparate |
commaSeparate(number) |
Number with thousands separators |
You can also combine Number (and similar numeric) fields with + - * / without a function. Choice fields that have calculation values can contribute those numbers when referenced in numeric mode.
What is not available?
Form Calculation does not offer: IF / AND / OR, DATEADD, EDATE, DATEDIF, NETWORKDAYS, addMonths, addYears, addWeeks (except as addDays(..., 7)), Excel lookup functions, or any function outside the table above. For show/hide or require logic based on values, use Show/Hide Field (and related) conditions instead of inventing an IF() in the formula.
How do I add three days to a date field?
Formula: addDays(Inspection date, 3) (replace the field label with yours).
Requirements so it works:
- The first argument must be a Date field (or
today()). A Number or Short Text field will not work as the date input. - The second argument is calendar days: a number literal such as
3, or a Number field. - There is no
DATEADD,EDATE,addMonths,addYears, or business-days function. Only calendar days viaaddDays/subtractDays. - When the formula uses
today,addDays, orsubtractDays, Formis displays the result as a date (default format likeMM/dd/yyyy). - If the Date field is empty, Null Handling decides whether the result blanks out (Propagate Null) or treats blanks in a zero-like way (Treat as Zero); for date math, prefer filled dates and Propagate Null when an empty input should yield no due date.
From today instead of a field: addDays(today(), 3).
Subtract five days from an end date: subtractDays(End date, 5).
How do I sum or average number fields?
Examples:
Quantity * Unit pricesum(Labor cost, Material cost)avg(Score 1, Score 2, Score 3)round(Total)
Rules: inputs should be numeric fields (Number, Spinner, Scale Rating, numeric list columns, or choice fields with calculation values). Leave Result Field Is Read Only on unless fillers must override the computed value.
How do I count selected checklist options?
count(Safety checklist)
The argument must be a choice-style field that supports multi-select counting (for example Checklist), not a free-text field.
How do I format a date or a large number as text?
dateString(Inspection date, "MM/dd/yyyy")commaSeparate(Contract value)
dateString returns text. Use it when you need a string (for example concatenating with other text in Text insert mode), not when you only need a date-style calculated display from addDays.
Options that change evaluation and display
Exact Options labels:
- Default Insert Mode: Numeric or Text (how newly inserted field tokens behave)
- Result Field Is Read Only: usually on so fillers cannot override the result
- Show Empty Decimal Places: for example show
5.00instead of5 - Ignore Hidden Fields: when on, fields with the designer Hide Field flag are treated as null/excluded. This does not follow fields hidden only by conditional Show/Hide rules
- Use Commas for Decimal Point: localization (for example
3,14) - Decimal Places:
0to10 - Null Handling: Treat as Zero or Propagate Null
- Error Handling: Show Blank or Show Error Badge