Limit End Date selections based on a Start Date input?

  • omaralraee
    Asked on July 1, 2018 at 3:42 AM

    My goal is to prevent the user from selecting an "End Date" input that precedes the "Start Date" input.

    For example, If the user selects 05-16-2018 for a Start Date input, the End Date input's available choices would begin on 05-16-2018 and all dates before 08-16-2016 would be unavailable.


    Can you help me please?

  • DonaldHag
    Replied on July 1, 2018 at 5:58 AM

    To achieve this, make use of the dates difference widget. Refer to this guide on adding widgets to your forms. Once a date is selected as a start date, only dates after that can date can be selected as end dates.

    Here is a working example: https://form.jotform.com/81427461769971 

    Clone and use it as required. 

    For further assistance, do let us know.

  • omaralraee
    Replied on July 1, 2018 at 11:07 AM

    Thanks for your response, but that's not helpful because in the data I need the dates to be single in the data submission.


    What should i do?

  • Nik_C
    Replied on July 1, 2018 at 12:24 PM

    As a workaround, you can do this:

    1) Add two date fields:

    1530461964Screen Shot 2018 07 01 at 6 Screenshot 10

    2) And you can add one Text field that will act as error:

    1530462078Screen Shot 2018 07 01 at 6 Screenshot 21

    3) Add a condition that will show that Text field if Date field 2 is before Date field 1 and it will hide Submit button:

    1530462142Screen Shot 2018 07 01 at 6 Screenshot 32

    4) This is how it works:

    1530462180Screen Shot 2018 07 01 at 6 Screenshot 43

    You can check my test form as well: https://form.jotform.com/81814488751971

    Thank you!