public void Load() { BinaryFormatter bin = new BinaryFormatter(); FileStream s = File.OpenRead(SavePath); ReferenceUpdate ru = (ReferenceUpdate)bin.Deserialize(s); s.Close(); AcceptedGreetings = ru.MoreGreetings; }
public void Save() { BinaryFormatter bin = new BinaryFormatter(); FileStream s = File.Create(SavePath); ReferenceUpdate ru = new ReferenceUpdate(); ru.MoreGreetings = AcceptedGreetings; bin.Serialize(s, ru); s.Close(); }