I am a newbie at Android programming.
I created a simple Empty Activity app in Android Studio and it has a bunch of UI fields. After I type in those input fields if I press the back button, the activity gets destroyed loosing all my entered data.
But if I press the home button and switch to another app and come back to my app the data is there.
What do i need to do so that I do not loose the data entered?
Update:
Looks like I will have to used shared preferences.
But wondering how the apps like Google Chrome might be persisting the huge amount of data like Web page, the input fields on the webpage etc