DEVANG SHARMA
DEVANG SHARMA

Reputation: 2662

Store Changes Of Layout Permanently After Closing The Application

I have a preference layout file, and i want to store all the changes in my layout

so the next time I open application it has new changes

Example---> Two Radio Buttons in an XML file 1) Blue (Checked) 2) Red (Unchecked)

Now when I Checked it to Red and close The Application then at next time when i run again

then it should has this manner in same XML file 1)Blue (Unchecked) 2)Red (Checked)

so please tell me how I do this.

waiting for your reply, thanks

Upvotes: 1

Views: 112

Answers (1)

Will Tate
Will Tate

Reputation: 33509

Devang,

You need a ChecKBoxPreference to store the value in SharedPreferences

This website provides a pretty good tutorial of all of the Preferences types that Android provides and how to save/restore them: http://www.kaloer.com/android-preferences

Good luck!

Upvotes: 2

Related Questions