Calculations
Create calculated fields that automatically compute values from other form fields.
Form creation requires a Pro plan or higher. Form filling is available on all plans.
Basic Calculations
Sum
Add multiple field values:
- Create a text field for the result
- Open properties → Calculate tab
- Select Sum
- Choose the fields to sum
Product
Multiply field values:
- Create a result field
- Open properties → Calculate tab
- Select Product
- Choose the fields to multiply
Average
Calculate the average:
- Create a result field
- Open properties → Calculate tab
- Select Average
- Choose the fields to average
Minimum
Find the smallest value:
- Create a result field
- Open properties → Calculate tab
- Select Minimum
- Choose the fields to compare
Maximum
Find the largest value:
- Create a result field
- Open properties → Calculate tab
- Select Maximum
- Choose the fields to compare
Custom Calculations
For complex calculations, use JavaScript:
- Create a result field
- Open properties → Calculate tab
- Select Custom calculation script
- Write your JavaScript
Example: Percentage
var subtotal = this.getField("subtotal").value;
var discount = this.getField("discount").value;
event.value = subtotal * (discount / 100);Example: Conditional
var quantity = this.getField("quantity").value;
var price = this.getField("price").value;
var discount = quantity > 10 ? 0.1 : 0;
event.value = (quantity * price) * (1 - discount);Calculation Order
When multiple fields have calculations:
- Click Forms → Calculation Order
- View the order of calculations
- Drag to reorder if needed
- Calculations run top to bottom
Calculation order matters! If Field C depends on Field B, Field B must calculate first.
Number Formatting
Format calculated results:
- Open field properties → Format tab
- Select Number
- Set decimal places
- Choose currency symbol if needed
- Set separator style
Common Patterns
Invoice Total
Subtotal = Sum(Line1, Line2, Line3, ...)
Tax = Subtotal * 0.08
Total = Subtotal + TaxOrder Form
Line Total = Quantity * Unit Price
Order Total = Sum(all Line Totals)
Shipping = (Order Total < 50) ? 5.99 : 0
Grand Total = Order Total + ShippingPercentage Complete
Completed = Sum(completed checkboxes)
Total = Count(all checkboxes)
Percentage = (Completed / Total) * 100Tips
- Name fields descriptively for easier scripting
- Test calculations with various inputs
- Handle division by zero
- Consider read-only for result fields
- Document complex calculations
Next Steps
- JavaScript Actions - Add custom form logic
- Text Fields - Add text input fields
- Selection Fields - Add checkboxes, radio buttons, and dropdowns
- Create Forms Tutorial - Step-by-step form creation walkthrough
Last updated on