Power Apps Timer Value to Hours, Minutes, Seconds

1


#PowerApps #TimerControl
Have you ever needed to track how long it’s taking to complete a process in your Power App? Using the Timer Control you can do that, however, the output of that timer value is stored in an unfriendly format. In this video, I show how you can take that timer value and format it in hours, minutes and seconds format.

Here’s the formula to output the timer control into this format:

With(
{
seconds: RoundUp(Timer1.Value/1000,1)
},
With(
{
minutes: RoundDown(seconds / 60,0),
secondsRemaining: Mod(
seconds,
60
)
},
With(
{hours: RoundDown(minutes / 60,0)},
hours & ” hour(s) ” & minutes & ” minute(s) ” & secondsRemaining & ” second(s)”
)
)
)

Checkout April’s Channel

Choose your Reaction!
  • Great video April. Just one question. The duration of the timer. What does it do? The 160k ms value. Seems like the text-string you are designing the label with, using the with function can spit out numbers greater than 160s. Other than that detail, very good sharing. =)

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.