static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); SerializeStatic.Load(typeof(Settings), Settings.FileNameSettings); Application.Run(new Form2()); }
private void Apply_BTN_Click(object sender, EventArgs e) { Settings.ShowAccent = ShowAccent_CB.Checked; SerializeStatic.Save(typeof(Settings), Settings.FileNameSettings); foreach (Category cat in Form2.lib.Categories) { if (cat.IsChanged) { cat.SaveSlova(); } } Form2.lib = new Lib(); isApplied = true; this.DialogResult = DialogResult.OK; this.Close(); }
private void Form2_FormClosing(object sender, FormClosingEventArgs e) { SerializeStatic.Save(typeof(Settings), Settings.FileNameSettings); }