private void btnProductSales_Click(object sender, EventArgs e) { if (Utility.gblnAccessControl) { if (!Utility.gblnChildPrivileges(strComID, Utility.gstrUserName, 166)) { MessageBox.Show("You have no Permission to Access", "Privileges", MessageBoxButtons.OK, MessageBoxIcon.Warning); return; } } if (System.Windows.Forms.Application.OpenForms["frmRptSpecialProduct"] as frmRptSpecialProduct == null) { frmRptSpecialProduct objfrm = new frmRptSpecialProduct(); //objfrm.m_action = (int)Utility.ACTION_MODE_ENUM.ADD_MODE; objfrm.strSelection = "Special Product Sales"; objfrm.strFromshow = "PackSise"; objfrm.Show(); objfrm.MdiParent = MdiParent; } else { frmRptSpecialProduct objfrm = (frmRptSpecialProduct)Application.OpenForms["frmRptSpecialProduct"]; objfrm.Focus(); objfrm.MdiParent = this.MdiParent; } }
private void btnSalesTarget_Click(object sender, EventArgs e) { if (Utility.gblnAccessControl) { if (!Utility.gblnChildPrivileges(strComID, Utility.gstrUserName, 165)) { MessageBox.Show("You have no Permission to Access", "Privileges", MessageBoxButtons.OK, MessageBoxIcon.Warning); return; } } if (System.Windows.Forms.Application.OpenForms["frmRptSpecialPartyReport"] as frmRptSpecialPartyReport == null) { frmRptSpecialProduct objfrm = new frmRptSpecialProduct(); objfrm.strSelection = "Special Product Target"; objfrm.strFromshow = "SpecialProductTarget"; objfrm.Show(); objfrm.MdiParent = MdiParent; } else { frmRptSpecialProduct objfrm = (frmRptSpecialProduct)Application.OpenForms["frmRptSpecialProduct"]; objfrm.Focus(); objfrm.MdiParent = this.MdiParent; } }