Using Conditions to populate a date field to a certain number of days after or before current date

  • Onondagaskiclub
    Asked on December 12, 2019 at 5:48 PM

    When using the conditions calculation to add or subtract a number of days from a specified date and then place the calculated date in a separate date picker  is giving inaccurate results. 

    For example, when I set the first date picker (Today) to the current date and then add 1 day using the conditions calculator, the date displayed in the second date picker (Calculated Date) field is the current date. If I add 2 days in the conditions calculator, then the Calculated Date field will show one day after the current date.  If I subtract one day using the  conditions calculator, the Calculated Date field will show 2 days before the current date. If I add or subtract Zero in the conditions calculator, the Calculated Date field will show one day before the current date. 

    I have provided a link to a simple form that illustrates the problem. I am also seeing this problem in our more detailed forms.

    Thank You

  • Girish JotForm Support
    Replied on December 12, 2019 at 10:03 PM

    Yes, I can see the issue on your form. Let me test and get back to you with an update.

  • Girish JotForm Support
    Replied on December 12, 2019 at 10:24 PM

    I think the issue could be related to the time zone difference. So when you increase the count by 1 on the calculation, it works fine.

    Example: If you want to increase by 1, add 2 to the current date; If you want to show the previous one date, then add 0 to the current date, etc as shown below.

    15762073251312 11 Screenshot 10

    Like wise for other date fields too.

    Here's the result:

    15762074601312 12 Screenshot 21

    Let us know if this works.