public MainForm() { Instance = this; category = new Categories(); InitializeComponent(); InitializeApp(); AppDomain.CurrentDomain.ProcessExit += new EventHandler(OnProcessExit); category = CategoryHandler.Load(CategoryHandler.filePath); category.InitUI(); ChangeAddButton(StateManager.APP_STATE); childForms = new List <Form>(); }
static void OnProcessExit(object sender, EventArgs e) { CategoryHandler.Save(); }