What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.


  • Profile Image

    How to calculate the discount total depending on the amount of options selected from the Multiple Choice field.

    Asked by K9Trio on June 01, 2017 at 12:56 AM

    Hi, I have a multiple choice field, I would like to put a total depending on what they chose. If they chose just one it's $125,  if they choose 2 it's 10% off, 3 15% off, 4 20% off.  I'm not sure what the conditional logic would be? Or do I have to have each of these in their separate field? Any help appreciated, formulas aren't my best thing.



    This is a re-post of a comment on Conditional Logic Inserts Text/Calculation Into A Field

  • Profile Image
    JotForm Support

    Answered by jonathan on June 01, 2017 at 01:32 AM

    You just need to assign calculation values first to the choices/options in the multiple choice field.

    Check this user guide: How-to-Assign-Calculation-Value

    Then use the Calculation widget to do the calculations. It will be simpler now since each of the choices/options have actual numeric value in Multiple Choice field.

    Let us know if you need further assistance.

     

  • Profile Image

    Answered by K9Trio on June 01, 2017 at 12:00 PM

    I've got that but don't know how to do the percentage discounts? i

    f they select more than one they get a discount depending on how many they have chosen. 

    If they choose 2 it's 10% off, 3 15% off, 4 20% off. It's not dependant on what choices. They can chose options 2, 4, 5 and they are to receive a 15% discount

    Or they can choose options 3 & 4 and get a 5% discount

    Or they can choose option 1, 2, 3, & 4 and get a 20% discount

  • Profile Image
    JotForm Support

    Answered by BDAVID on June 01, 2017 at 01:55 PM

    You can use conditional logic to calculate the percentage discount, what is the form you are working on? We will be glad to help you set it up.

  • Profile Image

    Answered by K9Trio on June 01, 2017 at 02:18 PM

    Hi, this is the form https://form.jotform.ca/62315122507243

     

    that would be great if you could help

  • Profile Image
    JotForm Support

    Answered by BDAVID on June 01, 2017 at 05:14 PM

    I have created the following workaround for you:

    1) Add 6 form calculations widgets(one for each of your products):

    2) Use conditions to output the value of "1" to each of them, if the corresponding product was selected.

    For example, if product one is selected, then the value "1" would be set in the widget called "Product 1".

    These are all the conditions:

    3) Add another Form Calculation widget, which I labeled as "Total Products selected", to sum all the previous fields(Product1Product2Product3Product4 + Product5 + Product6) .

    4) Add another Form Calculation widget which I labeled as "Discount total".

    5) Rename the Total Owing as "Subtotal Owing":

    6) Add another calculation widget(name it Total Owing) to calculate the total(subtotal - discount amount):

    7) Now, create the following conditions to calculation the discount amount:

    8) Finally, hide the fields you don't want to show to the user:

    Please test my clone version of your form: https://form.jotformpro.com/71516840780963 

    You can clone it and use it if you want to: https://www.jotform.com/help/42-How-to-Clone-an-Existing-Form-from-a-URL 

    Let us know if you have more questions.

  • Profile Image

    Answered by K9Trio on June 01, 2017 at 06:25 PM

    This is exactly what I needed thank you so much