Android Question Stopwatch and Services

brodmuehler

Member
Licensed User
Longtime User
Hi Everybody

I programmed a little and very simple stopwatch in order to learn how Services work. But this stopwatch is not working since it always falls behind as soon as my phone switches off. That means that I am doing something wrong.

Could someone perhaps have a look at my code and give me a hint what is wrong. Iam runningout of ideas and I cannot find a solution in the tutorials and examples.

I attached my app as a zip-file.

Thanks a lot and kind regards
René
 

Attachments

  • TestService.zip
    319.2 KB · Views: 232

brodmuehler

Member
Licensed User
Longtime User
Dear All

first of all thank you all for your great support and help. Without your help I would not have been able to crack this. My stopwatch is really working great now. I also had the idea to use the system-time in order to improve the accuracy of the stopwatch. And that is now really working. I attached my code (including all the help) in the case somebody is interested.

Gratefully
Rene
 

Attachments

  • TestService.zip
    394.5 KB · Views: 203
Upvote 0

Smee

Well-Known Member
Licensed User
Longtime User
I too would like to add my thanks, I have just dropped this into a program I am writing with design changes etc. It saved so much coding time. Thanks to all and special thanks to Rene for making his code available. Very much appreciated.
 
Upvote 0
Top