I'm trying to create a countup timer with milliseconds.
I used Chronometer but I don't know how to display milliseconds.

Chronometer crono = (Chronometer) findViewById(R.id.chrono);
        startTime = SystemClock.elapsedRealtime();
        crono.setOnChronometerTickListener(new
OnChronometerTickListener() {
            public void onChronometerTick(Chronometer arg0) {
                countUp = (SystemClock.elapsedRealtime() -
arg0.getBase()) / 1000;
                countUp_milli = (SystemClock.elapsedRealtime() -
arg0.getBase());
                String asText = (countUp / 60) + ":" + (countUp %
60);
                timeflg.setText(asText);
        }
});

crono.start();

please tell me how to display milliseconds.

Thank you

Hassy

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to