• Resolved Moiqc

    (@moiqc)


    Hi!

    First, thanks for this great plugin!

    I thought I would be able to find the answer for this one on google, but I can’t seem to find answers that I understand.

    How can I use the checkbox values in the calculated field?

    Ex:
    fieldname1:
    Make your choices:
    – choice one: 20$
    – choice two: 40$

    If user chooses one and two, how do I display the sum 60 in my calculated field?

    I tried something like fieldname1.getField(“choice one”).value + fieldname1.getField(“choice two”).value and other similar guesses, but couldn’t find it.

    Thanks!

    https://www.ads-software.com/plugins/calculated-fields-form/

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

    (@codepeople)

    Hi,

    The answer is very easy, you only should use the field name fieldname1, the calculated field sums the choices values by itself;

    If the user selects the choice one fieldname1 will be 20, if selects the choice two, fieldname1 will be 40, but if the user selects both choices, fieldname1 will be 60

    Best regards.

    Thread Starter Moiqc

    (@moiqc)

    Oh, indeed, I don’t know why it hadn’t worked the first time I tried it. Thanks for the prompt response!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Checkbox value’ is closed to new replies.