
Announcements
I'm trying to convert a variable with a string which contains a time hh:mm:ss to an integer or float that can be used to make calculations. I've searched and tried different solutions but found no solution to this issue. Does anyone know how to do this?
Hi @JoostvanDeelen,
The ticks function is pretty useful for this in Power Automate.
Below is an example of such a calculation with three expressions.
Start Time
ticks(formatDateTime('14:01:22', 'HH:mm:ss'))
End Time
ticks(formatDateTime('14:31:22', 'HH:mm:ss'))
Calculating time difference in minutes
div(sub(outputs('Compose_-_End_Time'),outputs('Compose_-_Start_Time')),600000000)