private void btnAdd_Click(object sender, EventArgs e) { frmProductionPlanDetail frm = new frmProductionPlanDetail(); if (frm.ShowDialog() == DialogResult.OK) { LoadInfoSearch(); } }
private void btnEdit_Click(object sender, EventArgs e) { int id = TextUtils.ToInt(grvData.GetFocusedRowCellValue(colID)); if (id == 0) { return; } ProductionPlanModel model = (ProductionPlanModel)ProductionPlanBO.Instance.FindByPK(id); frmProductionPlanDetail frm = new frmProductionPlanDetail(); frm.ProductionPlan = model; if (frm.ShowDialog() == DialogResult.OK) { LoadInfoSearch(); } }
// khởi tạo delegate để chuyển dữ liệu form này sang from detail // public delegate void delPassData(TextBox text); private void btnNew_Click(object sender, EventArgs e) { frmProductionPlanDetail frm = new frmProductionPlanDetail(); frm.Show(); }