Time Calculation employee time clock

If an employee clocks in at 9:30 and clock out at 11:15 how do I do that calculation in majic text to show 1:45 mins

Hi @GrantWoods,

If you use DateTime properties for Start and Finish times, then:

  • to get hours, we need to multiply the time difference by 24, as time measurement in Adalo is Day. Then we need to take the integer part of the result. Formula will look like: INT ( ( FinishTime - StartTime) * 24 )

  • getting remaining minutes is a bit more complex. We need to deduct the ‘integer’ number of hours (formula above) from the original time difference (( FinishTime - StartTime) * 24) - with this we’ll get remaining minutes. As the measurement here is Hour, we need to multiply it by 60 and take the integer part of the result (not to have 2.5515135 minutes).
    The formula should look like this: INT ( ( ( ( FinishTime - StartTime) * 24 ) - INT ( ( FinishTime - StartTime) * 24 ) ) * 60 )

Didn’t have time to test it in the app, unfortunately.

Best regards, Victor.

1 Like