To save data after user registration (when the user is created) ...
SharedPreferences login_app_preferences = context.getSharedPreferences("LOGIN_DETAILS", MODE_PRIVATE);
SharedPreferences.Editor editor = login_app_preferences.edit();
editor.putString("email", strEmailOrLoginId);
editor.putString("password", strPassword);
editor.commit();
To access it, somewhere in the application ....
// Get the app shared preferences
SharedPreferences login_app_preferences = context.getSharedPreferences("LOGIN_DETAILS", MODE_PRIVATE);
strUserName = login_app_preferences.getString("email", "");
strPassword = login_app_preferences.getString("password", "");
source
share