# How can I use conditions in a form?

• wolfpaw69
Asked on May 08, 2015 at 06:04 PM

I'm a home inspector, and I'm try to make a form customer can fill out.

I'm trying to use different fields where a customer can enter information and I can give them a cost output.

First field would be where customers enter square footage.  Second field would be the year a building was built.  Third field, location.  Fourth field, sheds or hot tubs.

I want to calculate an output based upon the input of these filed.

Example: House is 1550 sqft with a shed located 20 miles away.  Cost would be \$350

\$300 ---- 1501 to 2000 square feet

\$325 ---- 2001 to 2500 square feet

\$350 ---- 2501 to 3000 square feet

\$400 ---- 3001 to 3500 square feet

\$450 ---- over 3500 square feet

\$25 ----- Shed

\$25 ---- Hot tub

\$25 ----- Location: Pine (about 20 miles away)

• raul
Answered on May 08, 2015 at 06:17 PM

I suggest you to check the following guide: https://www.jotform.com/help/259-How-to-Perform-Calculation-in-the-Form which you can learn how to perform calculations in your form.

Also, you can check this guide: https://www.jotform.com/help/57-Smart-Forms-Using-Conditional-Logic to learn how to create conditions in a form. So for the example you provided you can create the if condition like this:

Please let us know if you need further assistance.

• wolfpaw69
Answered on May 16, 2015 at 09:13 PM

Excellent.  Your example helped me big time.  How do I enter the syntax for multiple conditions.  So I would want the output to be \$325 if the number entered was between 1501 and 2000.  In addition \$350 if the the number entered was between 2001 and 2500.

• raul
Answered on May 16, 2015 at 10:16 PM

So I would want the output to be \$325 if the number entered was between 1501 and 2000.

The condition would be the following:

In addition \$350 if the the number entered was between 2001 and 2500.

This would be the condition:

If you need further assistance, please let us know.

• wolfpaw69
Answered on May 20, 2015 at 11:36 AM

Sorry, I don't get it.  Your second example doesn't show the original \$325.  I'm trying for different outputs.

\$300 ---- 1501 to 2000 square feet

\$325 ---- 2001 to 2500 square feet

\$350 ---- 2501 to 3000 square feet

\$400 ---- 3001 to 3500 square feet

• wolfpaw69
Answered on May 20, 2015 at 11:53 AM

Oh, think I've got to start with a new Condition every time right.  So I give the first condition, then I  select the second conditions button (green cross arrows) and put in the second condition.

• wolfpaw69
Answered on May 20, 2015 at 11:55 AM

When I enter the 3rd condition, it doesn't work.  Anything over 2000 will give me 325.

• Kiran
Answered on May 20, 2015 at 12:48 PM

The rules in the condition should be having All instead of Any.

The condition is displayed as below :

Please try changing the Rule to All and it should work. Please let us know if you need any further assistance. We will be happy to help.

Thanks!

• wolfpaw69
Answered on May 21, 2015 at 04:49 PM

Thanks for your patience.  I'm new to this but I'm getting it.  By the way it worked.

• raul
Answered on May 21, 2015 at 05:54 PM

On behalf of my colleague, you're welcome.