示例#1
0
        private void totalDeJugadoresToolStripMenuItem_Click(object sender, EventArgs e)
        {
            nJugador nJugador = new nJugador();
            int      total    = 0;

            if (nJugador.listarJugadores() != null)
            {
                foreach (eJugador jugador in nJugador.listarJugadores())
                {
                    total += 1;
                }
            }
            MessageBox.Show("Total de jugadores:" + " " + total.ToString());
        }