• Resolved digiblogger

    (@digiblogger)


    I am using a calculation field that Returns something like that:

    if(fieldname37+fieldname38 > fieldname29) return "Important: The needed Volume is a least " + prec(fieldname48,2) + " ml!";

    That works so far, but:

    Even I set the decimal seperator as “,” and the thousands seperator as “.”, the Output of the Expression
    prec(fieldname48,2)
    is for example 136.00.

    How can I Output 136,00?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author codepeople

    (@codepeople)

    Hello @digiblogger

    If you are returning as the equation’s result a sentence, evidently the plugin cannot apply to it the format defined in the field’s settings. So, the alternative would be apply the formatting operation manually. Edit the piece of code:

    
    prec(fieldname48,2)
    

    as follows:

    
    fbuilderjQuery.fbuilder.calculator.format(PREC(fieldname48, 2), {decimalsymbol:',', groupingsymbol:'.'})
    

    and that’s all.
    Best regards.

    What is the syntax for wrapping PREC() around a calculated number? I tried PREC(((fieldname2*fieldname3*fieldname4)/144),2) but nothing is displaying.

    • This reply was modified 6 years, 10 months ago by RitoRawling.

    Solved my issue- sorry- not able to delete my post!

    Plugin Author codepeople

    (@codepeople)

    Hello @mchotzinoff

    Thank you very much for letting me know you have found the solution.

    Best regards.

    Thread Starter digiblogger

    (@digiblogger)

    Thanks for your superb help 🙂

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Using decimal/thousand seperator in Calculation fields’ is closed to new replies.