How do you store a timer value in Tiny databases

After your post only seeing that my gif post was marked as solution.. well, post#15 marked as solution? Well it have no relation with topic or query I think..

I just shared my view, may be even more simple way we can short it and if I come to know let me share it

And what is after restarting the app? It continiues ... but the OP wants to restart it at 0 (if I understood that correctly).

In such case user can use one exit button. And on clicking it save the tinydb counter value to zero.

Yes, but there are several other options to leave an app, eg device Back button, Home button and killing the app via task manager ...

Also it is not necessary to disable the Timer because it is disabled automatically if the screen is closed.

grafik

1 Like

This is not a solution (because it continues counting after restarting the app).

Another open question would be what should happen to the timer if Screen1 is no longer visible, eg the home button was pressed. I would assume that the count should not continue, but only as long as Screen1 is visible (i.e. in the foreground). Questions over questions... :wink:

I have solved the problem thanks to your and everybody else's solution, thank you

Please provide a screenshot of the solution to help others with similar questions in future
Thanks
Taifun

I will as soon as I can

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.