Hi! I’m trying to make a step tracker where when you press the start button on the 2nd screen, a timer fires but you only see the time elapsed in the 3rd screen (stats)
But it’s showing up like this and not tracking the time properly…help pls…
Hi! I’m trying to make a step tracker where when you press the start button on the 2nd screen, a timer fires but you only see the time elapsed in the 3rd screen (stats)
But it’s showing up like this and not tracking the time properly…help pls…
It isn’t necessary to add the update time
or even the updateElapsedTime
functions in your code. As long as your timers are starting at 00:00:00, and your timer is counting up by every second, it should be fine. Milliseconds can also count too.
I can provide an example below for you:
function timer:
if app variable TimerRunning = true:
format time
set Time_text text to:
join:
formatted_hours, ":", formatted_minutes, ":", formatted_seconds
else:
set formatted_hours to 0
set formatted_minutes to 0
set formatted_seconds to 0
Another error you’re probably encoutering is the zeroes. You’re combining a string and a number, which is not exactly ideal. Instead use number variables, and that might make your process a little better
If you could also tell me where you are testing this app on, that may be more useful to my understanding.