Advertisement
dzikovskyy

How to clear all activity stack in Android

Jun 16th, 2016
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.19 KB | None | 0 0
  1.         Intent intent = new Intent(CurrentActivity.this, NewActivity.class);
  2.         intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);
  3.         startActivity(intent);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement