//Program.csstatic void Main(){Application.EnableVisualStyles();Application.SetCompatibleTextRenderingDefault(false);Form1 Register = new Form1();Register.ShowDialog();if (Register.DialogResult == DialogResult.OK){Register.Dispose();Application.Run(new Form2()); //跳转form2}else if (Register.DialogResult == DialogResult.Cancel){Register.Dispose();return;}
//Form1.csprivate void button1_Click(object sender, EventArgs e){MessageBox.Show(\"Collecting successed!\"); //消息框this.DialogResult = DialogResult.OK; //界面跳转this.Dispose();this.Close();}