保存
SharedPreferences.Editor sp = getSharedPreferences("user",Context.MODE_PRIVATE).edit();
sp.putString("account",account);
sp.putString("pwd",password);
sp.commit();
读取
SharedPreferences sp = getSharedPreferences("user",Context.MODE_PRIVATE);
String account = sp.getString("account","");
String password = sp.getString("pwd","");
et_account.setText(account);
et_password.setText(password);
et_account、et_password是EditText