Each item in a WorkMobile form contains a piece of information, such as some text, a number, a date, and so on.
Many types of form item have a “formula” option. By adding a formula, it will automatically fill itself in with a calculated value. That calculation can be based on the values in other items on the same form.
If the mobile user keys something into the item with the formula, the formula is “overridden” by the keyed information.
Example
Many types of form item have a “formula” option. By adding a formula, it will automatically fill itself in with a calculated value. That calculation can be based on the values in other items on the same form.
If the mobile user keys something into the item with the formula, the formula is “overridden” by the keyed information.
Example
- Add two Number items to a form. Give the first one the caption Amount, and the second one the caption Times five.
- In the second one, add the following formula (note that formulae always have an “=” sign at the start):
=Amount * 5
- Save the form and publish it.
- Download the form to your mobile device.
- Open the form and type 7 into the “Amount” box. You should see 35 appear in the Times five box – the result of
There might be a short delay before it updates as the App waits a short time to make sure you’ve finished typing before it starts calculating.
Try changing the value in Amount. Times five will update accordingly. Try keying a value into Times five. Now change Amount. You should see that Times five no longer updates.
Try changing the value in Amount. Times five will update accordingly. Try keying a value into Times five. Now change Amount. You should see that Times five no longer updates.
Tip
You can prevent the mobile user from over-typing the value in an item by ticking the read only option for that item in the form designer.