예제 #1
0
        public static void menu()
        {
            Console.WriteLine("Please choose what you would like to do: ");
            Console.WriteLine("1. Login as a student.");
            Console.WriteLine("2. Login as a teacher.");
            Console.WriteLine("3. Register.");
            int menuChoice = Convert.ToInt32(Console.ReadLine());

            switch (menuChoice)
            {
            case 1:
                StudentLogin.LoginS();
                break;

            case 2:
                TeacherLogin.LoginT();
                break;

            case 3:
                Registration.menu();
                break;

            default:
                Console.WriteLine("You have made an invalid choice. Please try again.");
                break;
            }
        }
예제 #2
0
        public static void Register()
        {
            while (foundUser == true)
            {
                Console.Write("Please enter your username: "******"Please enter your password: "******"Please retype your password: "******"Registration was a success. Please log in!");
                    success = true;
                }
                else
                {
                    Console.WriteLine("The passwords do not match. Please try again.");
                }
            }

            TeacherLogin.LoginT();
        }