android - Restoring state of TextView after screen rotation? -


in app have textview , edittext. both have data in it. when screen orientation changes data in edittext remains, textview data cleared.

can 1 me out find way retain data in textview too?

if want force textview save state must add freezestext attribute:

<textview       ...       android:freezestext="true" /> 

from documentation on freezestext :

if set, text view include current complete text inside of frozen icicle in addition meta-data such current cursor position. default disabled; can useful when contents of text view not stored in persistent place such content provider


Comments

Popular posts from this blog

facebook - android ACTION_SEND to share with specific application only -

python - Creating a new virtualenv gives a permissions error -

javascript - cocos2d-js draw circle not instantly -