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

    Depending on the radio buttons selected price shows either with 2 decimal places or 1 decimal place with same setup (ALMOST FIXED)

    Asked by AA_C on May 14, 2016 at 03:41 PM

    When I select Oui that I am a member it uses 2 decimal points for total, when I select Non it uses 1 decimal point for total. I don't understand why?

    conditions form calculation decimal places
  • Profile Image

    Answered by Ben on May 14, 2016 at 03:52 PM

    The reason why that was happening Robert is because you have used conditions to add the value into the form calculation, while you have set the form calculation to show 0,00 all the time.

    I personally suggest to either use conditions on a textbox or use form calculation on its own, without any conditions adding value into it.

    You can use conditions to get data from it, just I would not recommend adding it into it.

    For example, what I tend to do if I need power of conditions and form calculation is to add the field to the form which I grab into the form calculation (by adding it in) and then use conditions to fill out that field (not the form calculation), which works just right ;)

    On your form, I have done the following:

    1. Disabled conditions that added value into the box

    2. set the form calculation as shown on the following screenshot:

    I did it on the form I shared with you on the previous thread: https://form.jotform.com/61345830191957

  • Profile Image

    Answered by AA_C on May 14, 2016 at 04:21 PM

    Hi Ben,

    If you look at the English equivalent form I get the trailing 0's weather I select member or non member. 61013950784960

    I was messing around with the French one today and added some additional conditions that offered nothing. I will be removing them. Your confusing me a bit with this $ USD thingy.

    We don't offer a US $ option. Canadian dollars only, a bit of a bargain for our American friends.

    Thanks Robert

  • Profile Image

    Answered by Ben on May 14, 2016 at 05:52 PM

    Sorry about that, my bad. the nicer looking dollars then it is ;)

    The same however applies as mentioned above.

    I have updated the form to show CAD only, while the rest is completely the same.

  • Profile Image

    Answered by AA_C on May 14, 2016 at 09:48 PM

    Ben... That's quite all right... Nicer looking but only worth .78c  

    This is the same solution you offered for the other issue... Good work two in one.

     

    If only all were so easy..

    Many thanks,

    Robert

  • Profile Image
    JotForm Support

    Answered by EltonCris on May 15, 2016 at 01:00 AM

    Glad my colleague's solution helped. 

    If there's anything else you need help with, or if you need further clarifications, let us know.

  • Profile Image

    Answered by AA_C on May 15, 2016 at 09:43 AM

    Hi JF,

    I just realized although this solution solves the issue with the user seeing the dollar in the correct format it is not the answer to the original question.

    When I select Oui that I am a member it uses 2 decimal points for total, when I select Non it uses 1 decimal point for total. I don't understand why?

    I have removed the redundant conditions as Ben indicated.

    What I view is for the Oui value I get 6.00 and for Non I get 7.5 not 7.50. This is a bit confusing as conditions are Identical only the value is different. I use the same logic conditions on the English form (61013950784960) and get the required results.

    This may be a mute point now as Ben's solution hides this from the end user, .... it just bugs me.

    So no urgency no this one, just a I would like to know why.

    Robert

  • Profile Image
    JotForm Support

    Answered by Kevin_G on May 15, 2016 at 12:01 PM

    After spending some time I found why this is happening, there is an option in the Form Calculation widget that allows to show all decimal numbers even when they are 0. 

    You should mark this option and the widget will show all the decimals exactly like you want, I made a sample form to show you how it works, you can take a look on this link: https://form.jotform.com/61354434120949

    Feel free to clone it

    So you need to make sure this option is marked in order to show 2 decimals, otherwise your result will be showing only one or if the result is, for example, 10.00 the result will be added without the decimals 10 only. 

    Hope this helps. 

  • Profile Image

    Answered by AA_C on May 16, 2016 at 10:24 AM

    Hi, 

    I see what you have done and it works just fine but I don't see how to do this on my form 53464905175965. I already have the "Show empty decimal places" checked on my calculations. 

    Can you clone my form and show me how Please? 

    As I said it works just fine on my English version; 61013950784960. 

     

    Thank you, 

     

    Robert

  • Profile Image
    JotForm Support

    Answered by EltonCris on May 16, 2016 at 11:56 AM

    Hello Robert,

    Were you able to resolve this? When I cloned your form, I can see that both Oui and Non total contains 2 decimal places.

    Example:

    Please let us know I have missed something here.

    Thanks!

  • Profile Image

    Answered by AA_C on May 17, 2016 at 09:56 AM

    Hello,

    Yes as you can see it is showing the correct decimal places, this is because of a previous fix for another issue resolved by Ben, so that it shows the user the proper value in French with the comma in place of the decimal point for cents and the dollar sign after the amount.

    Comma for Decimal

    As I said above;

    This may be a mute point now as Ben's solution hides this from the end user, .... it just bugs me.

    The PayPal box, that is now invisible to the user is where the issue lies. If you look at the values in that field you will see what I mean. You will have to remove the css code that hides it.

    Again not a big issue now as the other field displays it correctly it's just why is it working on the English version and not the French, I'm missing something.

    Not a high priority so don't spend a needless amount of time on it please. I'm just trying to understand where I went wrong for the next time.

    I hope this clears up the understanding of the issue.

    Many thanks to all,

    Robert

     

  • Profile Image
    JotForm Support

    Answered by Welvin on May 17, 2016 at 12:35 PM

    I'll be checking this and will ask my colleagues too. We'll let you know once we find the cause.

  • Profile Image

    Answered by AA_C on June 11, 2016 at 05:10 PM

    Hi, any further developments?....Robert

  • Profile Image
    JotForm Support

    Answered by liyam on June 11, 2016 at 10:15 PM

    We apologize for this delay. Let me forward this inquiry with Welvin and see if he found the cause.

    Thanks for your patience. 

  • Profile Image
    JotForm Support

    Answered by Welvin on June 18, 2016 at 05:30 AM

    Please check this form: https://form.jotform.com/61692212810954. You can clone this back to check how I calculated the fields. There are five calculations in the form just to get the decimal point to work :) I tried a few options but this is best that I came up with. 

    I hope this works for you and my apologies for waiting a month.