private void barangToolStripMenuItem_Click(object sender, EventArgs e) { form = Application.OpenForms["FormDaftarProduk"]; if (form == null) { FormDaftarProduk daftarBarang = new FormDaftarProduk(); daftarBarang.MdiParent = this; daftarBarang.Show(); } else { form.Show(); form.BringToFront(); } }
private void buttonMP1_Click(object sender, EventArgs e) { fo = Application.OpenForms["FormDaftarBarang"]; if (fo == null) { FormDaftarProduk fdp = new FormDaftarProduk(); fdp.Owner = this; fdp.Show(); } else { fo.Show(); fo.BringToFront(); } }