Date calculation: Adding 63 days on the selected date

  • vonlichtinger
    Asked on November 9, 2016 at 11:23 AM

    I need a form that will add dates for me.  

    ie:   11/01/2016  (starting date can be any date inserted by my customers)

     

    To that date they insert I need to add 63 days to this and end up with the date they will end on after 63 days 

     

    For example if I enter  the date 11/16/2016 I need 63 days added to that to end up with the final date ie: 01/18/2017

     

    This is a link to a page that has the type of calculation I am looking for  http://www.gsdceva.com/whelpcalc.htm

  • Jan
    Replied on November 9, 2016 at 1:50 PM

    It is possible to do a calculation in the date field. I created a demo form, please check this: https://form.jotform.com/63134898074969. You can clone it if you like to check the calculation.

    1. Insert "DateTime" field in the form and make sure that the Default Date is set to "Current".

    Date calculation: Adding 63 days on the selected date Image 1 Screenshot 50

    2. Insert a Form Calculation widget in the form.

    Date calculation: Adding 63 days on the selected date Image 2 Screenshot 61

    3. Use this formula: dateString(date+63).

    dateString() is a function inside the calculation widget.
    date0-9 is the date field in the form.
    + 63 is an operator and a normal number.

    Date calculation: Adding 63 days on the selected date Image 3 Screenshot 72

    Here's the result:

    Date calculation: Adding 63 days on the selected date Image 4 Screenshot 83

    Related guide: https://www.jotform.com/help/259-How-to-Perform-Calculation-in-the-Form

    Hope this helps. Thank you.