private void lbxScenarios_DoubleClick(object sender, EventArgs e) { try { clsGlobals.GIPar.ProductColorID = Convert.ToInt32(dgvResult.CurrentRow.Cells[0].Value); clsGlobals.ParentProductID = clsGlobals.GIPar.ProductColorID; if (clsProductEqui.ExistsEquivalence(clsGlobals.GIPar.ProductColorID)) { clsProductEqui myPequ = new clsProductEqui(); myPequ.GetProductEquiByPColorID(clsGlobals.GIPar.ProductColorID); clsGlobals.ProductEquiID = myPequ.ProductEquiID; MessageBox.Show("Exite equivalencia avec " + myPequ.CodeEqui + " en " + myPequ.NameSeason); } if (frOP == null) { frOP = new frmOrderProducts(); frOP.MdiParent = this.MdiParent; frOP.FormClosed += new FormClosedEventHandler(frOPFromClosed); frOP.Show(); } } catch (Exception ex) { MessageBox.Show(ex.Message); } }
private void frOPFromClosed(object sender, FormClosedEventArgs e) { frOP = null; }