How to hide Form fields based on age?

  • Profile Image
    muvanlier
    Asked on August 05, 2019 at 05:24 AM

    H there i want to create a dynamic age range for 18 years and older. in the calender a conditional logic should be present in which the user goes to the next question when there are 18 yers or older.

    Kind regards,

    Milenko

  • Profile Image
    roneet
    Answered on August 05, 2019 at 07:29 AM

    Let me make a demo Form for you. I'll get back to you in some time.

    Thanks.

  • Profile Image
    roneet
    Answered on August 05, 2019 at 08:03 AM

    You will have to add two Date Picker fields to your form. The first to ask the birth date and the second to show the current date. After that, you should calculate the day difference.

    Here is the workaround:

    1. Add another date field which will show the current date.

    15650057521.PNG

    2. Next, add a Form calculation field to calculate the age of the user using the following formulae:

    How to Perform Form Calculation Using a Widget

    15650061121.PNG

    3. Add a condition to hide the fields if age is greater than 18.

    15650065201.PNG

    Here is the Demo Form:

    https://form.jotform.com/92163316620955

    Let us know if you have further questions.

    Thanks.