To help follow example using SharedPreferences that I got from a project of mine:
public static final String MY_PREFS = "MEUAPP";
SharedPreferences preferences = getSharedPreferences(MY_PREFS, Context.MODE_PRIVATE);
SharedPreferences.Editor editor = preferences.edit();
editor.clear(); // No teu caso pode retirar o clear, eh que eu precisava que começasse vazio
editor.apply();
// Utilizo esse objeto collegeData pq estou pegando a informação de um retorno json, mas vc pode utilizar um TextView ali
editor.putInt("id", Integer.parseInt(collegeData.getString("id")));
editor.putString("nome", collegeData.getString("nome"));
To get the info that you have previously saved, just declare SharedPreferences again in the Activity you want.
public static final String MY_PREFS = "MEUAPP";
TextView name = (TextView) header.findViewById(R.id.nome_menu);
SharedPreferences prefs = getSharedPreferences(MY_PREFS, MODE_PRIVATE);
name.setText(prefs.getString("nome", null));