Q:

My welcome screen is not displayed when application runs for the second time

In my android application, there is a welcome screen.  It displays when I connect the USB cable to computer and test it.  
But when I open the application (once it has been installed) again in the phone, it doesn't display the welcome screen.  It directly goes to the second Activity.  Please help me with this.  
This is the code for the first screen.  
public class MainActivity extends Activity {

    Intent i;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);

        new Timer().schedule(new TimerTask(){
            public void run() { 
                startActivity(new Intent(MainActivity.this, MainMenu.class));
            }
        }, 2000 /*amount of time in milliseconds before execution*/ );
    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        // Inflate the menu; this adds items to the action bar if it is present. 
        getMenuInflater().inflate(R.menu.activity_main, menu);
        return true;
    }

}

I want to display the welcome screen every time when application is open.  
Thank you very much for your replies.  Actually all the solutions work when I commented this method in the MainMenu.java class. ( The Second Activity)
@Override
    public boolean onKeyDown(int keyCode, KeyEvent event) {
        if ((keyCode == KeyEvent. KEYCODE_BACK)) 
        {
            AlertDialog. Builder alertDialogBuilder = new AlertDialog. Builder(
                    context);

                // set title
                alertDialogBuilder.setTitle("Do you want to exit from Cooparate LOLC App?"); 

                // set dialog message
                alertDialogBuilder
                    .setMessage("Are you sure !") 
                    .setCancelable(false)
                    .setPositiveButton("Yes",new DialogInterface. OnClickListener() {
                        public void onClick(DialogInterface dialog,int id) {
                            // if this button is clicked, close current activity
                            Intent startMain = new Intent(Intent. ACTION_MAIN);
                            startMain.addCategory(Intent. CATEGORY_HOME);
                            startMain.setFlags(Intent. FLAG_ACTIVITY_NEW_TASK);
                            startActivity(startMain);
                        }
                      })
                    .setNegativeButton("No",new DialogInterface. OnClickListener() {
                        public void onClick(DialogInterface dialog,int id) {
                            // if this button is clicked, just close the dialog box and do nothing
                            dialog.cancel();
                        }
                    });

                    // create alert dialog
                    AlertDialog alertDialog = alertDialogBuilder.create();

                    // show it
                    alertDialog.show();
                }
        return super.onKeyDown(keyCode, event);
    }

But I want to appear a dialog box as in the above method when presses the back button.  How can I achieve the both tasks.  

Appear welcome screen everytime i open the App
Pop up a dialog box when I press the back button

A:

My guess is, that you might not be closing your app correctly with the "back" button.  
If you close it by pressing the "home" button, it will only be paused and stopped.  So as you can see from this diagram, when you open it again, onRestart() -> onStart() are called, but not onCreate(), so no welcome screen appears!