Date/Time Calculations

Viewing 2 reply threads
  • Author
    Posts
  • March 1, 2023 at 5:30 AM #49065

    Hans Fontius
    Participant

    Hello,

    I’m trying to calculate with Date/Time -> calculate hours/days between to dates.

    I’m attaching a form with my trials. It doesn’t work… Is there anybody to help me?

    Thanks

    Hans Fontius

    Attachments:
    You must be logged in to view attached files.
    March 1, 2023 at 1:12 PM #49067

    Daniel Leu
    Participant

    AFAIK HOURS() and DAYS() need to be all caps. The easiest is to double click on the function definitions on the right side of the formula editor.

    Still, this didn’t fix it and it always returned 0 hrs, 0 mins although the return value type was number. Strange. I then created a new calculation field with the correct calculation HOURS([Zeit 1];[Zeit 2]) and then it worked.

    March 1, 2023 at 10:23 PM #49077

    Brendan
    Keymaster

    There’s nothing wrong with your formulas. The issue was the Number Formatter you had set on the fields. You had them set to one of the Time number formatters. That won’t work because those number formatters are designed for durations measured in seconds. But the HOURS() and DAYS() functions return their values in hours and days, not seconds.

Viewing 2 reply threads

You must be logged in to reply to this topic.