//Open Child form void openChildForm(Form frmChild) { if (ActiveMdiChild != null) { ActiveMdiChild.Hide(); } frmChild.MdiParent = this; frmChild.Show(); }
private void CurrencyToolStripMenuItem_Click(object sender, EventArgs e) { if (ActiveMdiChild != null) { ActiveMdiChild.Hide(); } myForms["Currency"].Show(); }
public void HienThiQuyen_User() { btnDoiMatKhau.Enabled = true; HienThiKhoHang(); HienThiTrangChu(); label1.Visible = true; label1.Text = "Xin chào " + Access.HOTEN; btnNhaCC.Enabled = false; if (ActiveMdiChild != null) { ActiveMdiChild.Hide(); } }
private void CloseOpenedChildForm() { if (ActiveMdiChild != null) { if (ActiveMdiChild.Name.StartsWith("CreditBill") || ActiveMdiChild.Name.StartsWith("RetailBill") || ActiveMdiChild.Name.StartsWith("WholeSaleBill")) { ActiveMdiChild.Hide(); return; } ActiveMdiChild.Close(); } }
public void HienThiQuyen_ChiNhanh() { label1.Visible = true; label1.Text = "Xin chào " + Access.HOTEN; HienThiTrangChu(); HienThiQuanLyNhanVien(); HienThiKhoHang(); HienThiBaoCao(); //HienThiQuanLyNhanVien(); //HienThiKhoHang(); if (ActiveMdiChild != null) { ActiveMdiChild.Hide(); } }
public void check(Form a) { if (this.ActiveMdiChild != null && this.ActiveMdiChild != a) { ActiveMdiChild.Hide(); a.MdiParent = this; a.WindowState = FormWindowState.Maximized; a.Show(); } else { a.MdiParent = this; a.WindowState = FormWindowState.Maximized; a.Show(); } }
public void HienThiQuyen_CongTy() { label1.Visible = true; label1.Text = "Xin chào " + Access.HOTEN; btnDoiMatKhau.Enabled = true; //btnKhachHang.Enabled = true; rbpBaoCao.Visible = true; rbQLNhanvien.Visible = true; //btnMatHang.Enabled = true; btnDangXuat.Visible = true; btnTaoTK.Enabled = true; HienThiBaoCao(); //HienThiQuanLyNhanVien(); //HienThiKhoHang(); if (ActiveMdiChild != null) { ActiveMdiChild.Hide(); } }
private void btn_chart_Click(object sender, EventArgs e) { ButtonReset(); if (ActiveMdiChild != null) { if (this.ActiveMdiChild != mchildForm_Chart) { //ActiveMdiChild.Close(); ActiveMdiChild.Hide(); } mchildForm_Chart = ShowActiveForm(mchildForm_Chart, typeof(chart)) as chart; mchildForm_Chart.Show(); } else { mchildForm_Chart = ShowActiveForm(mchildForm_Chart, typeof(chart)) as chart; mchildForm_Chart.Show(); } btn_chart.BackColor = Color.Red; }
private void btn_alarm_Click(object sender, EventArgs e) { ButtonReset(); if (ActiveMdiChild != null) { if (this.ActiveMdiChild != mchildForm_Alarm) { //ActiveMdiChild.Close(); ActiveMdiChild.Hide(); } mchildForm_Alarm = ShowActiveForm(mchildForm_Alarm, typeof(alarm)) as alarm; mchildForm_Alarm.Show(); } else { mchildForm_Alarm = ShowActiveForm(mchildForm_Alarm, typeof(alarm)) as alarm; mchildForm_Alarm.Show(); } btn_alarm.BackColor = Color.Red; }
private void btn_search_Click(object sender, EventArgs e) { ButtonReset(); if (ActiveMdiChild != null) { if (this.ActiveMdiChild != mchildForm_Search) { //ActiveMdiChild.Close(); ActiveMdiChild.Hide(); } mchildForm_Search = ShowActiveForm(mchildForm_Search, typeof(search)) as search; mchildForm_Search.Show(); } else { mchildForm_Search = ShowActiveForm(mchildForm_Search, typeof(search)) as search; mchildForm_Search.Show(); } btn_search.BackColor = Color.Red; }
private void btn_monitoring_Click(object sender, EventArgs e) { ButtonReset(); if (ActiveMdiChild != null) { if (this.ActiveMdiChild != mchildForm_Monitoring) { //ActiveMdiChild.Close(); ActiveMdiChild.Hide(); } mchildForm_Monitoring = ShowActiveForm(mchildForm_Monitoring, typeof(monitoring)) as monitoring; mchildForm_Monitoring.Show(); } else { mchildForm_Monitoring = ShowActiveForm(mchildForm_Monitoring, typeof(monitoring)) as monitoring; mchildForm_Monitoring.Show(); } btn_monitoring.BackColor = Color.Red; }
private void Form1_Load(object sender, EventArgs e) { client = new SimpleTcpClient(); client.StringEncoder = Encoding.UTF8; client.DataReceived += Client_DataReceived; btn_monitoring.BackColor = Color.Red; //시작메뉴 모니터링 화면 if (ActiveMdiChild != null) { if (this.ActiveMdiChild != mchildForm_Monitoring) { //ActiveMdiChild.Close(); ActiveMdiChild.Hide(); } mchildForm_Monitoring = ShowActiveForm(mchildForm_Monitoring, typeof(monitoring)) as monitoring; } else { mchildForm_Monitoring = ShowActiveForm(mchildForm_Monitoring, typeof(monitoring)) as monitoring; } }
public void newElements() { ActiveMdiChild.Hide(); ne.Show(); }
public void mainView() { ActiveMdiChild.Hide(); m.Show(); }
public void newTable() { ActiveMdiChild.Hide(); nt.Show(); }