private void ribbonButton2_Click(object sender, EventArgs e) { foreach (Form f in this.MdiChildren) { if (f is DaftarSiswa) { //MessageBox.Show("Form2 is already opened."); return; } } CloseMdiForm(); _siswa = new DaftarSiswa(); _siswa.MdiParent = this; _siswa.Show(); }