private void housesToolStripMenuItem_Click(object sender, EventArgs e) { frmHouse fr = new frmHouse(); fr.MdiParent = this; fr.Show(); }
private void btnHouse_Click(object sender, EventArgs e) { foreach (Form frmCheck in MdiChildren) { if (frmCheck.GetType() == typeof(frmHouse)) { frmCheck.Activate(); return; } } Form frmChild = new frmHouse { MdiParent = this }; frmChild.Show(); }
private void addNewToolStripMenuItem_Click(object sender, EventArgs e) { frmHouse house = new frmHouse(); house.Show(); }