I have this note taking app where a user can type in what ever he wants to the textbox. But i also want the text to still be there even if the user exits the app. How can i apply onSavedInstantState and RestoreinstantState in the notes.java code?
public class notes extends Activity{
/** Called when the activity is first created. */
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.notes);
Button wg = (Button) findViewById(R.id.button3);
wg.setOnClickListener(new View.OnClickListener() {
public void onClick(View view) {
Intent intent = new Intent();
setResult(RESULT_OK, intent);
finish();
}
});
}
}