private void SaveToSettings() { lock (SyncRoot) { // Update the current profile with the new values so we can properly save it. settingsKey.SetValue(mruList.Take(MaxMRUCount).ToList()); save.Invoke(); // Ensure we are properly synchronized with the file. LoadFromSettings(); } }