private void button2_Click(object sender, EventArgs e)
 {
     //Edit account
     Form editAccounts = new AccountsForm();
     editAccounts.Show();
     this.Hide();
     editAccounts.FormClosed += otherFormClosed;
 }
        private void button2_Click(object sender, EventArgs e)
        {
            //Edit account
            Form editAccounts = new AccountsForm();

            editAccounts.Show();
            this.Hide();
            editAccounts.FormClosed += otherFormClosed;
        }