Start another activity with button

To run another activity when button is clicked you just need to add this code in your onClick method:

Intent intent =  new Intent(this, AnotherActivity.class);
startActivity(intent);

Hope this helps.

Leave a Comment