392
Views
2
Comments
Solved
Minutes to Hours
Question

Hey,

So let's say I have 12000 minutes, which I need to convert to Hours and leave minutes aswell if needed

so in this case it would be 12000/60 which is 200 hours, now let's say I have 12002 minutes and I need to do the same, it won't give me an integer and I need to recover those extra minutes right? So it would be 200 hours and 2 minutes, how can I make this conversion?

2019-05-22 11-30-09
Marcelo Ferreira
Solution

Hi Fábio,

There is an action on Outsystems called "Mod" it gives you the remainder of the division.

Regards,

Marcelo

2024-12-19 12-19-39
Amal
 
MVP

Hello Fabio, 

One possible solution could be to do a division by 60 that would give you the number of hours. 

Next you can use the Mod function to get the delta 

https://success.outsystems.com/Documentation/11/Reference/OutSystems_Language/Logic/Built-in_Functions/Math#Mod

Hope this should help !!!


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.