Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3331986
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T23:38:25+00:00 2026-05-17T23:38:25+00:00

My app has a feature like the BlackBerry Stopwatch application: A label displaying the

  • 0

My app has a feature like the BlackBerry Stopwatch application:
A label displaying the time, updated every 100 milliseconds.

I’ve used a separate thread for a Timer which schedules a TimerTask to update the label.

Everything works fine, but I’ve noticed the the stopwatch in my app runs a little bit slower than the built-in BlackBerry stopwatch — it loses 1 second per minute.
Sometimes the timer in my app halts for a while, about 300-500 milliseconds, for unknown reasons.

What could make the Timer in my app slower than the BlackBerry stopwatch?
Any suggestions to create a stopwatch which run as smoothly as the BlackBerry stopwatch?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T23:38:26+00:00Added an answer on May 17, 2026 at 11:38 pm

    You should use System.currentTimeMillis() to compute the time. The Timer does not guarantee when it will execute – the guarantee is that the specified time is the minimum delay until execution starts, but there is no maximum, as you’ve noticed. So use the Timer to schedule UI updates, but calculate the elapsed time using System.currentTimeMillis().

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've developed an Application (called Instant Buttons) and the app has a widget feature.
my app has a photoshop like feature wherein the user can create a new
Good time! My Android app has so feature that I use ListView in the
My app has to load an image from a http server and displaying it
I'm writing a web app which is used a SaS. Each customer has their
I would like to implement a feature in my application that allows the user
I use the mojolicious framework to write Web-App. Mojo::Base has a nice feature to
My client has just said that he would like me to implement a feature
I am intending to build an iPhone/iPad app that has a feature allowing users
I would like to create one feature in my app like in Twitter app

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.