Questions tagged [chronometer]

In Android, Chronometer is a class that implements a simple timer. Chronometer is a subclass of TextView. This class helps us to add a timer in our app. You can give Timer start time in the elapsedRealTime() timebase and it start counting from that. If we don’t give base time then it will use the time at which time we call start() method. By default a chronometer displays the current timer value in the form of MM:SS or H:MM:SS.

302 questions
0
votes
1 answer

android chronometer keeps resting

i have made a chronometer in my app. but when i turn of the screen in my phone after a while i look to see how much time passed and the chronometer is at zero again. how do i fix it so it doesent reset by itself? if(v.getId() == R.id.start){ …
0
votes
2 answers

Creating a GUI-based Chronometer (or Stopwatch)

What I took some time to work on is a program showing time elapsed, or time remaining, from where the user clicks the start button, much like a stopwatch or a chronometer which measures time until you stop and reset. Other examples of measuring time…
0
votes
2 answers

How to make a stopwatch windows form application

I am currently trying to make a chronometer in c# using the timespan class. So far I have been able to appropriately start, pause, and stop the chronometer, but I have been asked to make a lap button that registers the time in the chronometer upon…
user2738052
  • 23
  • 1
  • 4
  • 10
0
votes
1 answer

Android: chronometer stopwatch keeps overlapping

my stopwatch app keeps overlapping within itself, I added a background on the XML in both the background for the linearLayout and the Chronomemeter but it keeps on persisting
user2809321
  • 196
  • 1
  • 3
  • 17
0
votes
0 answers

Does the Chronometer Widget start by itself?

I initialized a Chronometer Widget like the normal way: mChronometer = (Chronometer) findViewById(R.id.chron); And although I dont start the Chronometer it begins to count. Why do this happen? And how can I avoid this?
silvia_aut
  • 1,481
  • 6
  • 19
  • 33
0
votes
0 answers

How to create a stopwatch timer without using "chronometer" class and just by using"SystemClock"--Android Phone App Developement

How can we write a stopwatch timer similar to the following (with the same functionality) without using chronometer class and solely by using "SystemClock" class? Most of the examples I have seen so far are either just using chronometer class or a…
Mona Jalal
  • 34,860
  • 64
  • 239
  • 408
0
votes
1 answer

android chronometer intervals and resetting

I'm working as a football (soccer) referee in Israel and I was asked to write an application that simulates our fitness test for the upcoming season. The test is an interval test, and the user can enter how much time does he run, walk and for how…
0
votes
0 answers

Automatic start Chronometer in Android

I would like to ask how can I able to start my chronometer without clicking a button? For example, if I click the "Play" button, the next chronometer in the next layout will automatically start. I tried to just start it in my level 1 class, but…
pingboo23
  • 137
  • 1
  • 3
  • 15
0
votes
1 answer

Using Chronometer Android

Good Morning! I´m trying to create a chronometer that works, when the condition in the parethesis is true, the 'stopwatch' started to count.. if the condition is false, only the textview is paused, it's not resuming, because it still running in…
0
votes
2 answers

display text when the timer reaches a specific time

i´m making an app that shows random sentences when you press a botton, this process is pefect, part of my code is: botonok.setOnClickListener(new OnClickListener() { public void onClick(View v) { Resources res =…
0
votes
1 answer

Starting chronometer with reDraw

Hi I am working on an android application which involves redrawing of the canvas and starting of chronometer at the same time. Anybody knows how can this be achieved? I have tried to call chronometer.start in View class when invalidate() is called.…
shannon
  • 579
  • 2
  • 10
  • 22
0
votes
1 answer

Android: why Chronometer.setText is not showing any text?

I want Chronometer to display my timer. When Chronometer.stop is called, i want to stop timer and display text at same place. Timer is getting stopped but after stopping when i try to setText("Stopped"); It is not working. Please let me know if…
parul
  • 363
  • 1
  • 6
  • 16
0
votes
1 answer

How to set time zone of Chronometer on android?

Chronometer's ticking is working But when I try to get how much time elapses by using following formula. %% SystemClock.elapsedRealtime() - cArg.getBase() it adds 12 hours more (minute and second are precise) it seems like I have to set time…
user1979727
  • 117
  • 1
  • 8
0
votes
1 answer

Best way to implement Timer in Android?

I doing some math game, and I have 25 question for user to answer. So, I want to mesaure how much time that user needed for solving that? So I need something like Timer, stopwatch with ability to pause time when user click on Back button. I saw few…
Zookey
  • 2,637
  • 13
  • 46
  • 80
0
votes
0 answers

Android Chronometer - One second "ticks" late

The app is a sports timer for cycling, skiing etc, where racers start at regular intervals. e.g. 1 minute. In my implementation of OnChronometerTickListener I notice that the calls occur at intervals significantly longer than 1000 mS. I use the…
BryanT
  • 412
  • 3
  • 12