How to Insert Text or Calculation into a Field Using Conditional Logic

November 26, 2021

We have just implemented this as a new feature allowing the use of Calculations based on specific conditions.

To learn more about this, here’s my test form. We’ll use it as a reference for the steps mentioned below.

  1. On Form Builder, go to Settings > Conditions.
  2. Then select the Update/Calculate Field option.

3. First, set up the IF statement – this is the rule that needs to be met for the conditional logic to trigger its action. Then, set up the DO statement to Calculate a field’s value.

Perform Calculations

Below is a screenshot of where we can do a calculation using the input from other fields. In my case, I will add the textboxes Number 1 and Number 2 then output it on a textbox named Total. This conditional action will happen only IF textbox Number 1Is Filled out. You can see this on my test form.

You can add the other form fields by clicking the Add Field button. Make sure that the fields are set to 0-9, meaning their value is numeric. You can also insert your own formula here, you can see the number pad on the right side and the math functions there.

After clicking the Save button, this is how it looks like in my conditions list.

Here’s how it looks like in the live form preview:

Insert Text

Now how to insert static text? Simply type the text in the textarea field under the DO statement. Set the target field where you want to output the text. In my case, this conditional action happens when the specific drop-down field in my form is set to “Yes”. Notice that the background color is different from a numeric input. It should have a light brown background (for texts) instead of black (for numbers).

This is how it looks like in my conditions list:

This is how it looks like in live form preview:

Congratulations! You’re now able to insert static text or perform your own calculations using Conditional Logic.

Here are some related guides that you might also want to check out:

Got questions? Please let us know below!

Was this guide helpful?
Contact Support:

Our customer support team is available 24/7 and our average response time is between one to two hours.
Our team can be contacted via:

Support Forum:

Contact Jotform Support:

Send Comment:

Jotform Avatar
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.