Question Type: Calculation

Contents

About

Calculations are used to add items like invoice totals, inspection scores and other calculated values in mobile forms. Use calculations to total work hours, find average inspection scores, and calculate costs within forms.

An example of a Calculation on an iOS device is shown below:

2018-12-27-CalculationiOS.png

Form Builder

In the Form Builder, the Calculation question appears as shown below:

2018-12-27-CalculationFB.png

The Question Edit screen for the Calculation question type has three tabs: General, Properties, and Help OptionsClosed Help Options are ways to add help content, such as YouTube videos, web pages, text, or images, to questions in a form. Mobile users simply tap the help icon next to a question to see the help that the form designer provided.. This article will go through each of the tabs.

General

Unique ID

The Unique IDClosed A Unique ID refers to the specific identifier of a question, form page, form section, or Data Destination. Unique IDs are used as reference points when pulling data for conditional logic, Analytics projects, Data Destinations, and Documents. is the reference for the question. For more information on Unique IDs, read: Overview: Unique IDs. It can either be auto-generated based on the question text, or customized.

Data Types

Data Types are the kind of information your mobile users will be putting into these questions. Setting a data type forces users to enter the kind of information you want in the correct format. This also ensures that the entered data can be used elsewhere in your business process, whether that's by other questions in the form, or in a data destination.

The Calculation question type supports the following data types:

Integer Decimal Currency
Calculation

Restrictions

Restrictions control how your mobile users interact with a question. They can be set on the question itself or controlled by Conditional Logic.

The following table shows which restrictions you can set for the question type. Note that:

  • indicates a restriction that you can configure.

  • * indicates a restriction that is always on.

  • ✘* indicates a restriction that is always off.

Required Read-Only Hidden on Device Hidden on Reports

Keep question width to 100%

(Side-by-Side SectionsClosed Side-by-Side Sections display questions and answers in a condensed, two-column layout. This can make it easier and faster for field users to scan, complete, and confirm the answers in a form. only)

Calculation ✘* ✓*

* Calculations are Read-Only by default, as the mobile user cannot interact with them. As the user cannot interact with the question, and the question is always answered ("0" is an answer), the question cannot be set to Required.

Properties

Calculation Builder

The calculation builder offers an easy, intuitive way to build your calculation questions. Calculation questions can only use information from numeric data type questions that come before it.

It allows you to:

  • Select appropriate, numeric data type questions from a dropdown.

  • Filter questions based on text typed in the calculation field.

    2018-12-27-CalculationBuild1.png

  • Add constants to calculations by typing them in (press "Enter" to select them).

    2018-12-27-CalculationBuild2.png

  • View any errors as you work on the calculation, making it easy to correct.

  • Set a Fallback/Default Value by clicking on the question in the calculation builder. This is the value that will be used if the question is not answered. The default setting is "0". If you are dividing by a question, the default value for the question should be set to "1" to avoid "divide by zero" errors.

    2018-12-27-CalculationBuild3.png

Data Type Properties

Properties allow you to set up your question in various ways. Question Properties change depending on the data type chosen.

Integer/Decimal/Currency
  • Allowable Range (Min/Max)
    • Note: If the calculated value falls outside of the allowable range, the user will have to adjust the answers to the questions used in the calculation; they cannot edit the calculation's answer directly.
  • Decimal Place Precision (Decimal Data Type)
    • If the calculated answer has more decimal places than allowed, it will be rounded to an allowed number using banker's rounding.
    • If it has fewer decimal places than allowed, .0's will be added
  • Currency

Answer Exceptions and Additional Comments

As Calculation questions use Numeric Data Types, you will have the option to use Answer Exceptions and Additional Comments.

Answer Exceptions

Answer Exceptions are used to categorize problems identified during the course of a field technician's work as the user completes a form. For example, if the total cost of parts on an Estimate form is outside of a certain range, the Calculation question can be highlighted to warn the user of a potential data entry error, or an excessive cost estimate.

For more information on setting up Answer Exceptions, please read: Answer Exceptions

Additional Comments

Additional Comments are useful for when certain answers from a user require further information, like a comment or reason. Using the same example as above, if a user adds an excessive number of parts to an Estimate form, a comment could be useful to provide additional details on why that number of parts is necessary.

For more information on configuring Additional Comments on questions, please read: Additional Comments on Questions

Help Options

Adding "Help" content to forms gives mobile users access to support and other resources out in the field. Help content is available to users through a button embedded beside a question. Any question in the form can include a link to YouTube videos, web pages, or work instructions.

For more information on Help Content, please read: Add Help Options to Questions