本帖最后由 xiandawang 于 2010-08-25 09:43:32 编辑

解决方案 »

  1.   

    非api方法,是调用窗体的Show。
    api方法,调用SetForegroundWindow(A_object.Handle)
      

  2.   

    Form2   form2=   new   Form2(); 
    private   void   button1_Click(object   sender,   EventArgs   e) 

            form2.WindowState   =   FormWindowState.Normal;   
            form2.Show(); 

      

  3.   

    给你一个简单的例子
    form1的创建form2的代码
            private void Form1_Load(object sender, EventArgs e)
            {
                Form2 form2 = new Form2(this);
                form2.Show();
            }
    form2的代码
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Text;
    using System.Windows.Forms;namespace WindowsApplication2
    {
        public partial class Form2 : Form
        {
            public Form2(Form1 parent)
            {
                InitializeComponent();            this.MdiParent = parent;
            }        private void timer1_Tick(object sender, EventArgs e)
            {
                this.MdiParent.WindowState = FormWindowState.Normal;  
            }
        }
    }记得定时器的Enable = true(在你想设置的地方)
      

  4.   

    给你一个简单的例子
    form1的创建form2的代码
      private void Form1_Load(object sender, EventArgs e)
      {
      Form2 form2 = new Form2(this);
      form2.Show();
      }
    form2的代码
    using System;
    using System.Collections.Generic;
    using System.ComponentModel;
    using System.Data;
    using System.Drawing;
    using System.Text;
    using System.Windows.Forms;namespace WindowsApplication2
    {
      public partial class Form2 : Form
      {
      public Form2(Form1 parent)
      {
      InitializeComponent();  this.MdiParent = parent;
      }  private void timer1_Tick(object sender, EventArgs e)
      {
      this.MdiParent.WindowState = FormWindowState.Normal;   
      }
      }
    }
      

  5.   

    LX你的道德太低了吧,完全copy我的代码!大家鄙视你!