private void tsbtnXuatHang_Click(object sender, EventArgs e) { if (!IsShow("frmXuatHang")) { frmXuatHang xuathang = new frmXuatHang(); xuathang.StartPosition = FormStartPosition.CenterScreen; xuathang.MdiParent = this; xuathang.Show(); } else { foreach (Form frmXuatHang in this.MdiChildren) { if (frmXuatHang.Name == "frmXuatHang") { frmXuatHang.Activate(); break; } } } }
private void mnuXuatHang_Click(object sender, EventArgs e) { frmXuatHang xuatHang = new frmXuatHang(); xuatHang.ShowDialog(); }