You are viewing limited content. For full access, please sign in.

Question

Question

Calculation Forms 10

asked on December 13, 2016

We are trying to calculate a fee based on the total number entered into a field.  

For example:

IF the number entered is 1-19 the calculation would multiply the number entered by value 1

IF the number entered is 20-59 the calculation would multiply the number entered by value 2

IF the number entered is 60+ the calculation would multiply the number entered by value 3

 

What is the calculation formula to accomplish this?

Thanks!

0 0

Answer

SELECTED ANSWER
replied on December 13, 2016

Assuming your form contains two number type fields where the first field (with variable name "Number") is the number that gets inputted and the second field is the calculated fee, you can use a formula like

=IF(Number<1,0,IF(Number<20,Number,IF(Number<60,PRODUCT(Number,2),PRODUCT(Number,3))))

1 0
replied on December 13, 2016

Okay this makes sense, but where do we put the value?  

 

i.e. If <20 multiply by 25 and if less than 60 but greater than 19 multiply by 23

 

Thanks for the help!

0 0
replied on December 13, 2016

Also - will this formula work in the "Calculation" Field in Forms?

0 0
replied on December 13, 2016

This formula goes into the field where you will display the fee. The logic is as follows:

  1. If the number is less than 1, then the fee will be 0
  2. Else, if the number is less than 20, then the fee will just be the number itself
  3. Else, if the number is less than 60, then the fee will be the number times two
  4. Else the fee will be the number times three

See this video for a demonstration.

1 0
replied on December 13, 2016

Awesome - thank you so much!  Got it working!

0 0
replied on October 2, 2017

Hi, is there documentation on a IF THEN formula in Forms based on the variable names? The help file only has documentation on math formulas.

0 0
replied on August 20, 2018

@████████ how would you approach this in a table? Or do you suggest a different way?

1 0
replied on February 6, 2019

@████████I used it in a table. FYI

1 0

Replies

You are not allowed to reply in this post.
You are not allowed to follow up in this post.

Sign in to reply to this post.