Form Calculations: How can I make the number display with two decimal places?

  • Profile Image
    gcook1868
    Asked on February 06, 2018 at 11:36 PM

    My field id is #input_24. The field is a calculated total payment amount. My problem is that, when the amount is 27.50 (American currency), it displays 27.5. How can I make the number display with two decimal places?



    This is a re-post of a comment on How to Inject Custom CSS Codes

  • Profile Image
    Ardian_L
    Answered on February 07, 2018 at 03:50 AM

    If the calculation number it has this value 17.23 it will show fully 17.23

    Unfortunately that functionality can not be changed, as there is no option on the Form Calculation widget to do that. If you want we can submit this as a feature request but I can't provide a timeline when this will be implemented.

    Please let us know so we can proceed. Thank you.

  • Profile Image
    gcook1868
    Answered on February 07, 2018 at 07:58 AM

    Actually, there is a "show empty decimal places" option on the widget that will do this easily. I found this by searching for Jotform information on Google. I hope this information will help you help other customers with the same question. Have a great day!

  • Profile Image
    gcook1868
    Answered on February 07, 2018 at 08:06 AM

    Create a calculated field using the "Advanced Designer" function. In Designer, click on the field. Click on the "widget settings" icon in the highlighted field box (top right), and then the "..." on the calculator pad and then "Options" tab. Click the "Show empty decimals" box. Below is the highlighted field showing the "widget settings" icon that looks like a magic wand. 

    --------------------------------------------------------------------------------------------------------------------------------------------->☟                                                                                                   

    1518008695Screen Shot 2018-02-07 at 6.59

  • Profile Image
    gcook1868
    Answered on February 07, 2018 at 08:08 AM

    Here is the Option "show empty decimals", that will cause the amount 27.50 to display "27.50" instead of "27.5". I set it to display 2 decimals places for this currency value.

    1518008844Screen Shot 2018-02-07 at 7.02

  • Profile Image
    Ardian_L
    Answered on February 07, 2018 at 08:11 AM

    Thank you very much for your helpful information. This will be really helpful for the users!

  • Profile Image
    gcook1868
    Answered on February 07, 2018 at 08:16 AM

    👍  Have a blessed day!