calculating time between two dateTimes

0
Hi all, I’m creating an app for recording working hours. the user should inserts his start time & Leaving Time, then the app should calculate the working hours.          these pictures for my microflow & the parameters. I want to ask if their anyway in Mendix to calculate the difference between two date times?.. because when I tried to use hoursBetween(dateTime()) function I got an error tells me the values of the function should be integers. but in my case how can I make the dateTime integer?  So, if there’s a solution for this issue it will be great. 
asked
1 answers
4

This can be done using the hoursBetween function

https://docs.mendix.com/refguide/between-date-function-calls/#5-hoursbetween 

 

The expression would be something like this: hoursBetween($WorkingHoursRecord/StartTime, $WorkingHoursRecord/EndTime)

answered