• Resolved Alwin

    (@wp-opti)


    I use a Number fieldname1 with a MAX setting of value 300. When the value is above 300 a warning message will be displayed.

    But in the same form there is a field (a Calculated Field) where I want to show a warning when the MAX value of the fieldname1 is above 200.

    Is that possible at all?

    Thank you very much!

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

    (@codepeople)

    Hello @wp-opti,

    The alternative would be assign the special attribute “max” to the calculated field programmatically.

    Assuming the name of the calculated field is: fieldname1, insert a “HTML Content” field in the form with the following piece of code as its content:

    
    <script>
    fbuilderjQuery(document).one('showHideDepEvent', function(){
    fbuilderjQuery('[id*="fieldname1_"]').attr('max',200);
    });
    </script>
    

    and that’s all.
    Best regards.

    Thread Starter Alwin

    (@wp-opti)

    Hello, thank you!

    I have added a “HTML content” field with this code but now 200 is the max value for all number fields. That’s not what I am after at.

    It is difficult to explain, maybe you can take a look at the form here:
    https://loeka.optiion.nl/printen/

    Now in the first 2 (number) fields there are max values settings:
    – the max for “Verticaal in cm” is 111 cm
    – the max for “Horizontaal in cm” is 300 cm

    When I higer value is entered a warning is displayed. So far so good…

    But then please look at these checkbox fields:

    -Polystyreen 1mm (maximaal 100×200 cm)
    -Polystyreen 2mm (maximaal 100×200 cm)
    -Polystyreen 3mm (maximaal 100×200 cm)

    When one of these options is selected in the checkbox then I would like to display a warning when the field “Verticaal in cm” is a higher value then 100 or/and the field
    “Horizontaal in cm” is a higher value then 200.

    So bisicly the fields “Verticaal in cm” and “Horizontaal in cm” have a max value setting in the field setting itself, but I would like to use other max settings in other places in the form.

    I hope you understand my question; thank you very much in advance for your help!

    Regards,
    Alwin

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