switch activity android studio code example
Example 1: android how to switch between activities
Intent intent = new Intent(getApplicationContext(), ActivityToBeOpened.class);
startActivity(intent);
Example 2: switch activity android studi
Intent intent = new Intent(this, DisplayMessageActivity.class);
startActivity(intent);