[分享]判断窗体是否唯一
private void childFrmExist()
{
if (newFrm == null || newFrm.IsDisposed)
{
newFrm = new Form2();
newFrm.MdiParent = this;
newFrm.Show();
}
else
{
newFrm.Activate();
}
}
private void button1_Click(object sender, EventArgs e)
{
childFrmExist();
}