private void accountsCreate_Button_Click(object sender, EventArgs e) { Main.AccountIndex = null; var account_Form = new Account_Form(); account_Form.AccountFormClosed += new EventHandler(accountForm_Closed); account_Form.Show(); this.Enabled = false; }
private void accountsEdit_Button_Click(object sender, EventArgs e) { if (Main.AccountIndex == null) { MessageBox.Show("Must select item to edit", "Invalid Selection"); return; } var account_Form = new Account_Form(); account_Form.AccountFormClosed += new EventHandler(accountForm_Closed); account_Form.Show(); this.Enabled = false; }