How to Disable Back Button Press in Android
This tutorial explains step by step how to disable back button in Android Application. This is one of the most needed things as you want to continue doing the work without any disturbance or interruption.
Please follow the steps below in order disable back button in Android Application:
1.Open Android Studio and go to MainActivity.java. Nothing has to be done in the Activity Main.
2.Enter a code in the Override method. The code being
public void onBackPressed()
3.You will find there is no Back button working from your Android App.