schnie wrote: > I am having the exact same problem. It's like the application > completely restarts itself when the phone is rotated. > > On Jan 12, 12:34 pm, Tommy <[email protected]> wrote: >> Hi I was wondering how to save the active screen view when the phone >> is rotated. Right now I have a listview that contains a bunch of >> entries when I rotate the phone everything on the screen gets replaced >> to its original state.
By default, the foreground activity is destroyed and recreated when the orientation changes. Use onSaveInstanceState() (preferred) or onRetainNonConfigurationInstance() (for things that can't go in a Bundle) to have your old activity's data be available to the new activity. -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training in US: 22-26 February 2010: http://onlc.com
-- 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

