-2
public class MainActivity extends Activity {


/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);


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

}

}

this is my main luncher activity (MainActivity) i am trying to start new activity called Main. so far so good the application load successfully but when i press the Home btn and return to desktop the application closed without any error and i cant return to it. also when i see the background apps my app isnt there

4

1 回答 1

0

如果您的“不保留活动”复选框处于打开状态,请检查您的模拟器/手机中的开发人员设置。设置 > 开发人员选项 - 底部的应用程序部分。如果选中,则取消选中。你的解释不足以解决这个问题。

于 2013-01-25T21:09:41.440 回答