コード例 #1
0
ファイル: MDIForm.cs プロジェクト: iraychen/OfficeRibbon
 private void ribbonButton2_Click(object sender, EventArgs e)
 {
     foreach (Form f in this.MdiChildren)
     {
         if (f.GetType() == typeof(MDIChild1))
         {
             f.Activate();
             return;
         }
     }
     Form form = new MDIChild1();
     form.MdiParent = this;
     form.Show();
 }
コード例 #2
0
        private void ribbonButton2_Click(object sender, EventArgs e)
        {
            foreach (Form f in this.MdiChildren)
            {
                if (f.GetType() == typeof(MDIChild1))
                {
                    f.Activate();
                    return;
                }
            }
            Form form = new MDIChild1();

            form.MdiParent = this;
            form.Show();
        }