コード例 #1
0
        public static void option1()
        {
            Console.WriteLine("Choose an operation from the following list:");
            Console.WriteLine("\tc - Open Checking Account");
            Console.WriteLine("\tb - Open Business Account");
            Console.WriteLine("\tl - Loan Account");
            Console.WriteLine("\tt - Term Deposit Account");
            Console.WriteLine("\te - Exit");

            Console.Write("Your option? : ");
            string option1 = Console.ReadLine();

            while (string.IsNullOrEmpty(option1))
            {
                Console.WriteLine("Your Selection can't be empty! Input your selection once more");
                option1 = Console.ReadLine();
            }


            if (option1 == "c")
            {
                AccountCreation.AccountNumber();
                option2();
                checking++;
            }
            else if (option1 == "b")
            {
                AccountCreation.AccountNumber();
                option2();
                businessAcc++;
            }
            else if (option1 == "l")
            {
                AccountCreation.AccountNumber();
                option2();
                loan++;
            }
            else if (option1 == "t")
            {
                AccountCreation.AccountNumber();
                option2();
                cd++;
            }
            else if (option1 == "e")
            {
                Console.WriteLine("\n\n THANKS FOR USING OUT ATM SERVICE");
                endApp = true;
            }
            else
            {
                while (!(option1 == "c") || (option1 == "b") || (option1 == "l") || (option1 == "t") || (option1 == "e"))

                {
                    Console.WriteLine("Please Enter the above option. ");
                    option1 = Console.ReadLine();
                }
            }
        }
コード例 #2
0
ファイル: Checking.cs プロジェクト: Din-esh-g/RevProject0
        public static void chekingAccount()

        {
            var newAccountN = AccountCreation.AccountNumber();
            var chAccount   = "CHK-" + newAccountN;
        }