I want that a new activity should start with some delay on pressing a button. Is it possible to do that , and whats the procedure.
Use a postDelayed() call with a runnable that launches your activity. An example code could be
//will care for all posts
Handler mHandler = new Handler();
//the button's onclick method
onClick(...)
{
mHandler.postDelayed(mLaunchTask,MYDELAYTIME);
}
//will launch the activity
private Runnable mLaunchTask = new Runnable() {
public void run() {
Intent i = new Intent(getApplicationContext(),MYACTIVITY.CLASS);
startActivity(i);
}
};
Note that this lets the interface remain reactive. You should then care for removing the onclick listener from your button.