A way to prevent multiple instances of the same intent on button click in Android application
Sometimes while pressing a button repeatedly causes multiple instance of the same intent in android applications. To resolve this issue use intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP) where you are creating the intent in your application, before starting the activity. Like below —
Intent intent = new Intent(this, YourClas.class);
intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP);
startActivityForResult(intent, INTENT_ID);