Calculate the Departure and Arrival

  • benny JotForm Support Manager
    Asked on November 23, 2021 at 2:57 AM

    I would like to form automatically calculate the number of parking days between departure (delivering car) and arrival (collecting car) and show it in "Total costs".

    Thanks so much!

  • mertucar1994
    Replied on November 23, 2021 at 3:59 AM

    Hello benny,

    It is possible to automatically calculate the number of parking days between departure and arrival days and add it to "Total costs" using Jotform. To do this, please follow the instructions given below:

    1. Select the form you wish to add this feature and click the Edit button:
    (screenshot)

    2. In the Build Settings, please add two Date Picker elements by clicking the Add Form Element button on the left side of your screen:
    (screenshot)

    3. Date picker text can be changed to Departure Date and Arrival Date by clicking gear icon on right side of the date picker element:
    (screenshot)

    4. In the Build Settings, please go to Add Form Element section and add Form Calculation widget in widgets section:
    (screenshot)

    5. Form Calculation Widget Settings can be opened by clicking the pen icon on right side of the widget:
    (screenshot)

    6. Parking cost can be calculated by Arrival Date minus Departure Date within paranthesis and then multiply it by fee amount in the Form Calculation Widget. To do this, please click to paranthesis opener button and then Add Field button to select your Arrival Date and Departure Date. Paranthesis can be closed by clicking to Back button and click close paranthesis button:
    (GIF)

    The cost will be shown in the Parking Cost section automatically after both dates are picked:
    (screenshot)

    If you need further assistance, please contact us again.