How to disable dates based on another date field

  • yolandaproduction
    Asked on April 20, 2024 at 5:07 AM

    Good day, I love your forms, it makes it easy for our clients to complete, but I see that they struggle with the dates (:-0

    So we have the following (we work in film):
    A Due Date - this is when they require our work
    A Shooting Date - this is when our work will be used

    Now, some of our clients chooses the shooting date and then that is before the due date, which does not make sense.

    So what I would love to do is the following:
    Still have my due date (I use the date picker)
    Still have my shooting date (date picker), but now I want to grey out the dates as selected on my due date calendar.

    Thus if they choose the 27 April as the due date, I do not want them to be able to choose any dates on or before the 27th April on the shooting day calendar. Is this at all possible?

    I did go to Conditions and tried out a few of the conditions, but there is nothing specifically for this.

    Thank you so much for these forms, I really appreciate them
    Have a blessed day / evening (whenever you receive this)

    YOLANDA

  • Sigit JotForm Support
    Replied on April 20, 2024 at 7:00 AM

    Hi Yolanda,

    Thanks for reaching out to Jotform Support. Please allow me some time to conduct tests. I'll get back to you once I have an update.

  • Sigit JotForm Support
    Replied on April 20, 2024 at 7:59 AM

    Hi Yolanda,

    Thanks for your patience. While there's currently no option to grey out the dates as selected on the due date calendar, you have the option to create a form condition to check whether the shooting date is equal to or before the due date. Additionally, you can add a paragraph field to notify the form filler to make corrections if any of the conditions are met. Let me show you how.

    1. In the Form Builder, add a Paragraph element to the form, placing it below the shooting date.
    2. Add some text to notify the form filler if they set the shooting date equal to or before the due date.
    3. Create a form condition to show/hide the paragraph element based on the user's answer.

    How to disable dates based on another date field Image 1 Screenshot 30

    As shown in the screencast below.

    How to disable dates based on another date field Image 2 Screenshot 41

    Here's a cloned form that you can use to test the above functionality. Please let us know if there's anything else we can do for you.

 
Your Answer