private void btnSuaTN_Click(object sender, EventArgs e)
        {
            if (!isAdmin)
            {
                return;
            }


            DataGridViewRow row = dataGridView2.CurrentRow;

            switch (tab.action)
            {
            case ActionForm.THEM:

                if (row != null)
                {
                    FrmThanNhan frm = new FrmThanNhan(row.Cells["HOTEN"].Value.ToString(), row.Cells["GIOI_TINHTN"].Value.ToString(), row.Cells["QUANHE"].Value.ToString(), row.Cells["NAMSINH"].Value.ToString(), row.Cells["NGHENGHIEP"].Value.ToString());
                    frm.edit = new FrmThanNhan.AddNewTN(EditTN);
                    frm.ShowDialog();
                }
                break;

            case ActionForm.KHONG:
            case ActionForm.SUA:
                if (row != null)
                {
                    FrmThanNhan frm1 = new FrmThanNhan(row.Cells["MAQHGD"].Value.ToString(), row.Cells["HOTEN"].Value.ToString(), row.Cells["GIOI_TINHTN"].Value.ToString(), row.Cells["QUANHE"].Value.ToString(), row.Cells["NAMSINH"].Value.ToString(), row.Cells["NGHENGHIEP"].Value.ToString());
                    frm1.edit = new FrmThanNhan.AddNewTN(EditTN);
                    frm1.ShowDialog();
                }
                break;
            }
        }
        private void btnThemTN_Click(object sender, EventArgs e)
        {
            if (!isAdmin)
            {
                return;
            }
            switch (tab.action)
            {
            case ActionForm.THEM:
                FrmThanNhan frm = new FrmThanNhan();
                frm.addnew = new FrmThanNhan.AddNewTN(AddNewTN);
                frm.ShowDialog();
                break;

            case ActionForm.KHONG:
            case ActionForm.SUA:
                if (dataGridView1.CurrentRow != null)
                {
                    FrmThanNhan frm1 = new FrmThanNhan(dataGridView1.CurrentRow.Cells["MAHS"].Value.ToString());
                    frm1.addnewid = new FrmThanNhan.AddNewTNWithId(AddNewTNId);
                    frm1.ShowDialog();
                }
                break;
            }
        }