private void BtnCalc_Click(object sender, EventArgs e)
        {
            lbxOutputNames.Items.Clear();
            lbxOutputNames.Items.AddRange(Operations.StudentNames.ToArray());

            myStudents = new Students();

            //Instantiate the lists = names

            int countTo = Operations.StudentNameCount + 1;

            myStudents.StudentHistory = new List <string> [countTo];

            for (int i = 1; i < countTo; i++)
            {
                myStudents.StudentHistory[i] = new List <string>();
            }
            lbxOutput.Items.Clear();

            // GenerateGroups(); //on the Form

            //loads the number combinations generated
            lbxOutput.Items.AddRange(GenerateStudentGroups.GenerateGroups(myStudents).ToArray());

            //  lbxOutput.Items.AddRange(GenerateStudentGroups.GenerateGroups(myStudents));



            // this.Text = myStudents.Countgroups.ToString();
            btnCalc.Text = "Groups Generated = " + myStudents.Countgroups.ToString();

            GenerateNameGroups();
        }
Exemple #2
0
        public int CountUniquesGenerated(Students myStudents)
        {
            var output = GenerateStudentGroups.GenerateGroups(myStudents);

            return(myStudents.Countgroups);
        }