Timer Code:
new Handler().postDelayed(new Runnable() {
@Override
public void run() {
Intent i =new Intent(getApplicationContext(),MainActivity2.class);
//or
startActivity(i);
finish();
}
},5000);
Timer Code:
new Handler().postDelayed(new Runnable() {
@Override
public void run() {
Intent i =new Intent(getApplicationContext(),MainActivity2.class);
//or
startActivity(i);
finish();
}
},5000);