I have a skeleton system of Activities that will eventually be filled
with GUI elements, but for now I just want to work on a particular
aspect of the project without developing the initial GUI parts first.
But, when I try to launch an Intent from onResume, I get a
RuntimeException in ActivityThread.performResumeActivity. What is
wrong with the following code?
public class Test extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
}
public void onResume() {
Intent i = new Intent(this, SecondActivity.class);
this.startActivity(i);
}
public class SecondActivity extends Activity {
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
}
}
}
Thanks,
Ben
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
-~----------~----~----~----~------~----~------~--~---