You can use bundle in onPause(). onPause() will call all the time, whenever the activity lose focus, or when the activity is invisble and can restore in onResume() as well.
Nithin On Jan 13, 2:28 pm, Android Developer <[email protected]> wrote: > Hi, > > Is it possible to use bundle and save the data in OnPause() lifecycle > method? > The scenario is i have 2 edit text and have entered some data > i want to retain the data when the activity is killed and started > again. > > This can be achieved using onSaveInstanceState() but as documentation > says, this method is not a lifecycle method and hence the callback is > not guaranteed. > > So i wanted to know if there is a way to save it using Bundle in > onPause().
-- 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

