private void btnThemSach_Click(object sender, EventArgs e) { Forms.frmSach frmS = new Forms.frmSach(); frmS.myEvent += frm_myEvent; frmS.ShowDialog(); }
private void btnChinhSua_Click(object sender, EventArgs e) { try { string _mas = grid_Sach.GetRowCellValue(grid_Sach.FocusedRowHandle, grid_Sach.Columns["MaSach"]).ToString(); // Truyen cai MaTL vua lay dx...qua ben form NhapTheLoai. Forms.frmSach frmS = new Forms.frmSach(_mas); frmS.myEvent += frm_myEvent; txtTim.Text = ""; frmS.ShowDialog(); } catch { XtraMessageBox.Show("Bạn phải chọn dòng chứa dữ liệu", Text, MessageBoxButtons.OK, MessageBoxIcon.Error); } }