How can I assign a calculated value to the Date Picker widget?

  • Bethany
    Asked on April 24, 2021 at 9:27 PM

    I am not trying to calculate a date, per se, just trying to set the date picker to a specific date via conditional logic. I have been searching for the correct format to send to the date picker field and it doesn't appear to be anywhere on the help site. Should it be sent the date in epoch format? I've tried guessing a couple formats and ended up showing the years 1899 and 1407, haha! :P Thank you!

  • Bethany
    Replied on April 24, 2021 at 10:48 PM

    In case anyone else has this question, I think I figure it out after trial and many errors. The date picker appears to want the YYYY-MM-DD format. However, for some reason I haven't yet determined, it sets it a day before the day I send it. So if I conditionally set the Date field to 2021-04-24 then in my table it appears as 2021-04-23. I have no idea why that is happening, but I need a fixed date so I can just set it to a day ahead of the one I need and it works. Good enough for now!

  • Marco JotForm Support
    Replied on April 25, 2021 at 12:05 PM

    Hello there,

    Thanks for reaching out to us!

    We're glad that you've been able to troubleshoot your issue and make your form work according to your needs!

    Let us know if you need further assistance,