I am developing an Android Application, where I have an imageView on a page and onLongClick it changes from Image A to Image B. However, when they leave the page the imageView goes back to Image A. How can I save the state (im guessing its done onpause, stop and destroy) so that it saves the current image src of the ImageView and load it up next time the page is accessed and created. I have never done data saving in Android..
Any simple data saving tutorial/example would be greatly appreciated.
Something along these lines should help you out:
Make sure you set the image variable to the proper resource at the same time you change it in your click listener.
If you're looking to remember the state longer than this, look into SharedPreferences.