I call multiple Handlers by new Handler().postDelayed(new Runnable()..... How can I stop it when I click on back?
public class MyActivity extends AppCompatA
You can define a boolean and change it to false when you want to stop handler. Like this..
boolean stop = false; handler.postDelayed(new Runnable() { @Override public void run() { //do your work here.. if (!stop) { handler.postDelayed(this, delay); } } }, delay);