In my code I'm getting milliseconds using
// elaspsed time in milliseconds
public long getElapsedTime() {
if (running) {
return System.currentTimeMillis() - startTime;
}
return stopTime - startTime;
}
As long is a whole number Where as I want to get the milliseconds in 00.0000 format However I've tried this so far
return ((System.currentTimeMillis() - startTime) / 1000f);
but I am not getting to particular format