Rank: Newbie
Groups: Registered
Joined: 1/9/2021(UTC) Posts: 3 Thanks: 1 times
|
Hi, I'm new to MobileTogether and trying the possibilities to create some kind of smart stopwatch to measure route durations. I couldn't find a way to start a stopwatch/timer after a user clicks on a button. What would be the best way to achieve the timer to be updated? Every 100ms would be nice, or at least every second. THanks
|
|
|
|
Rank: Administration
Groups: Registered, Administrators Joined: 7/21/2014(UTC) Posts: 498
Was thanked: 88 time(s) in 88 post(s)
|
You can achieve this by using page refresh timer.
Use Page Actions menu to define actions for your main page. Switch here to OnPageRefresh tab and check "Every ... seconds". Set the value for seconds to 0.100 which corresponds to 100ms
A page refresh time is started automatically when you enter the page which defines one. But you can also start and stop it explicitly with the action Restart/Stop Page Timer
Hope this helps
|
|
|
|
Rank: Newbie
Groups: Registered
Joined: 1/9/2021(UTC) Posts: 3 Thanks: 1 times
|
Thanks, I've managed to to that now but I cannot display the page timer in a label field. I did not find the page timer variable anywhere in the list. Is it available?
|
|
|
|
Rank: Administration
Groups: Registered, Administrators Joined: 7/21/2014(UTC) Posts: 498
Was thanked: 88 time(s) in 88 post(s)
|
There is no such global variable. But you can save the start time in a tree node, for example, and use it to display the timer. Attached is just one of many possibilities to do this
|
1 user thanked bbv for this useful post.
|
|
|
Rank: Newbie
Groups: Registered
Joined: 1/9/2021(UTC) Posts: 3 Thanks: 1 times
|
|
|
|
|
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.