private void BtnSim1_Click(object sender, EventArgs e) { var tela2 = new Tela2(); tela2.ShowDialog(); Hide(); }
private void btnBack_Click(object sender, EventArgs e) { if (Application.OpenForms.OfType <Tela2>().Count() > 0) { Form Jogo = Application.OpenForms["Tela2"]; Jogo.Show(); this.Hide(); } else { Form Jogo = new Tela2(); Jogo.Show(); this.Hide(); } }