Calculate Elapsed Time

  • MaidCrew
    Asked on September 19, 2020 at 10:37 AM

    Hi... Is there a way to render the amount of time elapsed based on current time (in Form2) minus a date/time captured in Form1 and pre-populated into Form2 field by way of a URL parameter.

    Example:

    1......  Form1 has a DatePicker element with date & time option set as "Current" and labeled "StartTime"  .... form is submitted at 9:00 am.

    2......  User is emailed link to Form2 with the “starttime” field value (from Form1) pre-populated into "starttime" field in Form2 through parameter within the URL.

    3......  At 10:30am User clicks URL-link to form2… form2 opens with starttime field prepopulated with 9:00 am by means of the URL.

    4......  Widget within form2 (digital clock widget?) captures CURRENT, dynamic/active time while form2 is open or being accessed.

    5......  Form calculation captures current time (from digital clock widget?), subtracts starttime field value and produces “amount of time elapsed” which dynamically updates with every second/minute that passes.

    Is this possible?

     

  • Vanessa_T
    Replied on September 19, 2020 at 1:41 PM

    1-3) It seems that you are already able to cover this one. Nonetheless, to prepopulate via URL, please follow this guide:

    How-to-Automatically-Pass-Form-Data-to-Another-Form

    4-5) It is not possible to dynamically update the time difference every second that the time pass by. I suggest using a regular Date Picker field instead on your Form2, then add a Form Calculation widget to calculate the difference on the time passed from Form1, to the Date Picker field on Form2. Kindly refer to the guide below when calculating time related values.

    Mastering-Date-and-Time-Calculation