0

I want to write a incomplete app state to a file if user leaves the app without saving the state. I believe I have to use onPause(). Is this recommended practice? (In onPause() i am going to encrypt the string and then create a file and store it, so bit time consuming).

If onPause() is not the place how to save the state?

pats
  • 1,273
  • 2
  • 20
  • 43

1 Answers1

0

Yes You an Save The Data onResume() State

@Override
    protected void onPause() {
        // TODO Auto-generated method stub
        super.onPause();
       // DO your stuff here 
    }
Quick learner
  • 10,632
  • 4
  • 45
  • 55