Timer doesn't depend on javafx and you can log and it will show on the terminal.
Just be careful to call startmessageloop before the app shutdown itself.
B4X:
Dim clock as timer
Public sub app_start(args() as string)
Clock.initialize ("clock",1000)
Clock.enabled = true
StartMessageLoop
End sub
Private sub clock_tick
Log("tick')
End sub
Timer doesn't depend on javafx and you can log and it will show on the terminal.
Just be careful to call startmessageloop before the app shutdown itself.
B4X:
Dim clock as timer
Public sub app_start(args() as string)
Clock.initialize ("clock",1000)
Clock.enabled = true
StartMessageLoop
End sub
Private sub clock_tick
Log("tick')
End sub
Thanks, EnriqueGonzalez as always. I wrote my question wrong. What you gave me works but what I am after is the numeric count 1,2,3,4,5...
I guess I need to use counter with the clock or timer to format it?
You need to increment a value like you wish. A count is not part of the Timer function.
Create a global integer value, set it to 0 in app_start and increment it in the timer_tick. Check the value whenever you need to know the actual counter...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.