读
PreferenceManager.GetDefaultSharedPreferences(this).GetInt("uid", 0);
写
var editor = PreferenceManager.GetDefaultSharedPreferences(this).Edit(); editor.PutInt("uid", id); editor.Apply();