Thread CheckCon; //检查网络的线程 //ShowEventHandle showEvent = null; #endregion /// <summary> /// 窗体加载方法 /// </summary> /// <param name="sender">本窗体</param> /// <param name="e"></param> private void Form1_Load(object sender, EventArgs e) { this.SetBounds((Screen.GetBounds(this).Width / 2) - (this.Width / 2), (Screen.GetBounds(this).Height / 2) - (this.Height / 2), this.Width, this.Height, BoundsSpecified.Location); // 窗体剧中 Win32.AnimateWindow(this.Handle, 2000, Win32.AW_BLEND); //窗体渐变 form2 = new Window2cs(); mModel = MessageModel.instance(); huaTongWebService = new WebReference.Service(); timer1.Enabled = true; }
public void fun() { try { form2 = new Window2cs(this); this.Width = 885; this.Height = 496; this.SetBounds((Screen.GetBounds(this).Width / 2) - (this.Width / 2), (Screen.GetBounds(this).Height / 2) - (this.Height / 2), this.Width, this.Height, BoundsSpecified.Location); form2.Show(); groupBox3.Controls.Clear(); groupBox3.Controls.Add(form2); form2.ConnectStatus(); setToolstrip(); SetToolstripValue(); } catch (Exception exception) { MessageBox.Show(exception.Message); } }
public Form3(Window2cs form) : this() { Window = new Window2cs(); }