Checking Age and show age dependent Message

  • aktivamembers
    Asked on July 1, 2021 at 5:38 AM

    Hi, can I check the age with a field like this?


    1625132070 60dd8c2691d06  Screenshot 10

    I need this birthday field to check if someone is over 18 years old and if not, it should be possible to send the form but it should show a simple special text message. Can I create this somehow? I want the birthday date in three parts, not as one line ...


    Thanks for help in advance.

  • Cecile JotForm Support
    Replied on July 1, 2021 at 8:21 AM

    Hello there,

    Please allow me some time to check on this and get back to you with relevant information.

    Thank you.

  • Cecile JotForm Support
    Replied on July 1, 2021 at 8:55 AM

    Thank you for waiting.

    You might consider using DatePicker instead. To separate month, day, and year , you just need to turn off Lite Mode.

    1625143312 60ddb810cfa7c 6 Screenshot 10

    To achieve your requirement, we must (1) calculate the age and (2) show/hide the message depending on the age.

    (1) Calculate the age

    My colleague has explained how to calculate age from birthday on this thread: https://www.jotform.com/answers/2531106-how-to-calculate-age-from-birthday

    (2) Show/Hide Message

    To achieve this, I added two paragraph fields containing different messages.

    1625143796 60ddb9f41752b 7 Screenshot 21

    Then, I created the conditions below.

    1625143855 60ddba2f5b8ec 8 Screenshot 32

    Guide: How-to-show-or-hide-fields-base-on-users-answer


    Result:

    1625143645 60ddb95d8c820 5 Screenshot 43

    Feel free to clone my demo form to test: https://form.jotform.com/211813649462963

    Guide: https://www.jotform.com/help/42-how-to-clone-an-existing-form-from-a-url

    I hope this helps.

    Should you have further inquiries, kindly let us know.

  • aktivamembers
    Replied on July 2, 2021 at 6:04 AM

    Hi Cecile, thank you so much, it worked great that way ... it helped a lot ...