How can I start and stop my countdowntimer via a button?
Well... maybe you need to first understand how Java and programming work. Then, you can try to do something like this:
CountDownTimer aCounter = new CountDownTimer(100000 , 1000) {
public void onTick(long millisUntilFinished) {
mTextField.setText("Seconds remaining: " + millisUntilFinished / 1000);
}
public void onFinish() {
mTextField.setText("Finished");
}
};
aCounter.start();