private void addMemberToolStripMenuItem_Click(object sender, EventArgs e) { AddUpdateMemberFrm addMember = new AddUpdateMemberFrm(false); addMember.FormClosing += new FormClosingEventHandler(this.MemberUpdated); addMember.ShowDialog(); }
private void editMemberToolStripMenuItem_Click(object sender, EventArgs e) { if (membersDataGridView.Rows.Count == 0) { return; } int id = Convert.ToInt32(membersDataGridView.SelectedRows[0].Cells["memberId"].Value); Member member = new MembersController().Show(id); AddUpdateMemberFrm editMember = new AddUpdateMemberFrm(true, member); editMember.FormClosing += new FormClosingEventHandler(this.MemberUpdated); editMember.ShowDialog(); }