private void Check(User user) { this.testing1.Stop(); this.button1.Enabled = true; if(user.Error == ErrorStatus.None) { this.toolStripStatusLabel1.Text = ErrorStatus.None.ToString(); this.Hide(); mf = new NewForm(_c,user,_cs); mf.Show(); this.mf.Closed += delegate(object senderd, EventArgs ed) { if(this.CloseVar == true) { this.Close(); }else{ this.Show(); this.CloseVar = true; } }; this.mf.logi += ChangeClose; }else if(user.Error == ErrorStatus.PassWrong){ foreach(ErrorStatus es in user.GetErrors()) { this.toolStripStatusLabel1.Text = es.ToString(); } } }