Checking Age and show age dependent Message

  • Profile Image
    aktivamembers
    Asked on July 01, 2021 at 05:38 AM

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


    1625132070_60dd8c2691d06_

    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.

  • Profile Image
    Cecile_A
    Answered on July 01, 2021 at 08:21 AM

    Hello there,

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

    Thank you.

  • Profile Image
    Cecile_A
    Answered on July 01, 2021 at 08: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.png

    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.png

    Then, I created the conditions below.

    1625143855_60ddba2f5b8ec_8.png

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


    Result:

    1625143645_60ddb95d8c820_5.gif

    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.

  • Profile Image
    aktivamembers
    Answered on July 02, 2021 at 06:04 AM

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