I have a chronometer and am using mChronometer.getText();how do I convert this to an int? using Integer.parseInt(); throws an error because mChronometer.getText(); outputs in the form minutes : seconds
if you are using android.widget.Chronometer you can get the elapsed time with :
int elapsedMillis = (int) (SystemClock.elapsedRealtime() - mChronometer.getBase());
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With