/// <summary> /// Transition to the form of a choice of categories. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void Button1Click(object sender, EventArgs e) { Form3 f3 = new Form3(); f3.Opacity = 0; f3.Show(); for (int i = 0; i <= 100; i++) { f3.Opacity = i / 100.0; System.Threading.Thread.Sleep(1);//чем меньше число, тем быстрее появится } this.Close(); }
/// <summary> /// Return on the form with a category choice. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void Button1Click(object sender, EventArgs e) { Game.RightWordsCounter = 0; g.LastNumberCounter = 0; g.WrongLettersCounter = 0; Game.CorrectLettersCounter = 0; // Transition to the form back. Form3 f3 = new Form3(); f3.Opacity = 0; f3.Show(); for (int i = 0; i <= 100; i++) { f3.Opacity = i / 100.0; System.Threading.Thread.Sleep(1);//чем меньше число, тем быстрее появится } this.Close(); }
/// <summary> /// Transition to the form of a choice of categories. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void Button1Click(object sender, EventArgs e) { Form3 f3 = new Form3(); this.Hide(); f3.Show(); }
/// <summary> /// Return on the form with a category choice. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void Button1Click(object sender, EventArgs e) { Game.RightWordsCounter = 0; g.LastNumberCounter = 0; g.WrongLettersCounter = 0; Game.CorrectLettersCounter = 0; // Transition to the form back. Form3 f3 = new Form3(); this.Close(); f3.Show(); }