public void InitForm() { frmManageDocument = new FrmManageDocument(IDNhanVien); btnMasterControl.Enabled = false; frmSearchBug = new FrmSearchBug(); btnUseDocument.Enabled = false; frmscale = new FrmScaleAddTool(); btnScaleAdapterTool.Enabled = false; frmCheckgia = new FrmCheckGia(); btnCheckPrice.Enabled = false; frmkiot = new Frmkiot(); frmSyncPrice = new FrmSyncPrice(); frmbangbaogia = new FrmbangBaoGia(); frmDonDatHang = new FrmDonDatHang.FrmDonDatHang(this); quanlyDdh = new FrmQuanlyDDH(); frmCheckCKTM = new FrmCheckSKU_CKTM(); frmKiemTrafileT = new FrmCheckFileT(); frmCheckCurency = new FrmCheckCurrentcy(); //btcheckcurrentcy.Enabled = false; btbangbaogia.Enabled = false; btSyncPrice.Enabled = false; btbangbaogia.Enabled = false; btnKHTVCheck.Enabled = false; btCheckCKTM.Enabled = false; frm = new FrmImage(); }
private void btnScaleAdapterTool_LinkClicked(object sender, NavBarLinkEventArgs e) { if (!CTLQuanLyForm.formName.Contains(frmscale.Name)) { if (frmscale != null) { frmscale = new FrmScaleAddTool(); xtraTabbedMdiManager.MdiParent = this; CTLQuanLyForm.formName.Add(frmscale.Name); frmscale.Text = "Tool Cân"; frmscale.MdiParent = this; frmscale.Show(); } else { frmscale = new FrmScaleAddTool(); xtraTabbedMdiManager.MdiParent = this; CTLQuanLyForm.formName.Add(frmscale.Name); frmscale.Text = "Tool Cân"; frmscale.MdiParent = this; frmscale.Show(); } } else { if (frmscale == null) { frmscale = new FrmScaleAddTool(); frmscale.MdiParent = this; frmscale.Activate(); frmscale.BringToFront(); } else { frmscale.MdiParent = this; frmscale.Activate(); frmscale.BringToFront(); } } }