Change Calculation Field based on a Text Input

  • Profile Image
    Asked on January 27, 2015 at 07:02 PM

    We are going to use stripe to process payments. How we have it set up is we have a calculation field that calculates values of other inputs selected in the form, adds up, and gives a total in that calculation field. Once there is a total, that is copied to the stripe total field.

    What I would like to do is this: Once there is a total in the calculation, have it read a text based input from another field (We will title it Promo Code) and then reduce that total by a certain percentage based on the text input.

    Is this possible? 

  • Profile Image
    Answered on January 27, 2015 at 10:04 PM


    Yes I believe that is possible, in my case this is what I have in mind.

    Here's a demo form that I made:

    1. I added text box fields and form calculation widgets.

    2. In the form calculation widget named "Pre-Calculated without Promo Code" I added input 1 and input 2, this will be the total without the promo code.

    3. I then setup a condition where when the pre-calculated field is filled, the promo code text box will show. The other condition then will have a rule where when the user adds the promo code "CODE1", it will deduct 5 to the total of precalculated field.


    From there, you can pass the total form calculation field to the Payment integration wizard.

    To not make your form too messy, you can just hide the fields, don't worry, hidden fields will still work, we will just use them as storage for our values.

    You can check my form further by cloning it using this guide:

    I hope that helps. Do let us know if you need more assistance on this.

    Thank you.