Support Forum

Ask questions and get help from MobileTogether experts.
MobileTogether Product Information
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
View
Go to last post Go to first unread
javo  
#1 Posted : Saturday, January 9, 2021 10:55:01 PM(UTC)
javo

Rank: Newbie

Groups: Registered
Joined: 1/9/2021(UTC)
Posts: 3
Sweden

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
bbv  
#2 Posted : Saturday, January 9, 2021 11:12:15 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 448

Was thanked: 77 time(s) in 77 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
javo  
#3 Posted : Sunday, January 10, 2021 10:24:55 AM(UTC)
javo

Rank: Newbie

Groups: Registered
Joined: 1/9/2021(UTC)
Posts: 3
Sweden

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?
bbv  
#4 Posted : Sunday, January 10, 2021 7:44:17 PM(UTC)
bbv

Rank: Administration

Groups: Registered, Administrators
Joined: 7/21/2014(UTC)
Posts: 448

Was thanked: 77 time(s) in 77 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
File Attachment(s):
TimerSample.mtd (6kb) downloaded 3 time(s).
thanks 1 user thanked bbv for this useful post.
javo on 1/10/2021(UTC)
javo  
#5 Posted : Sunday, January 10, 2021 8:28:09 PM(UTC)
javo

Rank: Newbie

Groups: Registered
Joined: 1/9/2021(UTC)
Posts: 3
Sweden

Thanks: 1 times
Thanks that worked!
Users browsing this topic
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.