How to limit an amount to 2 decimals?

  • Simonlunt
    Asked on July 27, 2018 at 5:33 PM

    Please can you tell me how to stop user entering more than 2 decimal places in my spend field ?

    https://form.jotformeu.com/82024015917349

  • Kevin Support Team Lead
    Replied on July 27, 2018 at 5:36 PM

    You may use the Masked Input widget to achieve it, you will only need to configure the widget to have 2 decimal places: 

    1532727302screenshot 01 Screenshot 10

    You will find the widget here: https://widgets.jotform.com/widget/masked_input 

    This guide will help you adding the widget to your form: https://www.jotform.com/help/252-How-to-Add-a-Widget-to-Your-Form 

    An example can be seen here: https://form.jotform.com/60276535070957

    I hope this helps. 

  • Simonlunt
    Replied on July 27, 2018 at 5:51 PM

    Thanks. I have found that widget to be a bit flaky on some browsers.

    I found the Currency validation in the short text field . This looks to do the best job ?

  • jonathan
    Replied on July 27, 2018 at 6:31 PM

    The Currency validation option should work.

    Example:

    1532730661zzz 2018 07 28 06 Screenshot 10


    Let us know if you need further assistance.