Date and Time Calculations

Viewing 3 reply threads
  • Author
    Posts
  • February 16, 2017 at 2:07 AM #21133

    Christie Goodman
    Participant

    I have repeatedly hit a stumbling block with using TapForms. I need more ability to put in date related calculations.

    For instance, I need to calculate the time resulting from adding 20 hours to TIME X. (TIME X is a previous field in the form.)

    Can this be done? How?

    Christie

    February 16, 2017 at 2:46 AM #21134

    Brendan
    Keymaster

    Hi Christie,

    Yes this can be done. You just have to know one thing about Tap Forms. All date calculations use seconds as the units.

    So if you want to add 20 hours to a time, then you need to get your field and add 20 x 60 x 60 to it. Because there’s 60 seconds in a minute and 60 minutes in an hour.

    So your formula is: 20 * 60 * 60 * [Time Field]

    February 17, 2017 at 9:45 PM #21185

    Mike Schwartz
    Participant

    Um, wouldn’t that be 20*60*60 + [Time Field] ?

    February 17, 2017 at 10:50 PM #21189

    Brendan
    Keymaster

    Oops. Yes you’re right Mike. My brain fart.

Viewing 3 reply threads

You must be logged in to reply to this topic.