jgostylo wrote: > This is what I am doing: > > Activity SplashScreen is the launching activity for my app. It sends > a request to my server and gets back a user data it then uses to > populate a user object which is a static object. Once it has that it > calls the MyMapView activity and finishes itself. > > A force close occurs when I hit the home button and then open up > enough other apps so that Android kills MyMapView to get more > resources. Now when I open my app again it tries to start MyMapView > and bypasses SplashScreen. There is no user object so I get null > pointer exceptions. > > I have tried to Override the onSaveInstanceState and > OnRestoreInstanceState but it seems that those are not available when > Android kills the activity.
No, but onSaveInstanceState() will be called in and around the onPause() and onStop() calls, so they most definitely will have been called by the time your process is terminated, given your above scenario. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy _The Busy Coder's Guide to Android Development_ Version 3.0 Available! -- 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

