public void WithdrawalBalance(String anumber) { int limit = 50000; var amountTotal = _model.GetByAccountNumber(anumber); if (amountTotal.Balance <= limit) { Console.WriteLine("The amount in the account must be over 50000 (VNĐ)"); } else { YYTransactionHistory h = new YYTransactionHistory(); Console.WriteLine("Please enter the amount you need to withdraw"); decimal amount = Decimal.Parse(Console.ReadLine()); if ((amountTotal.Balance - amount) < limit) { Console.WriteLine("The amount you can withdraw is currently: " + (amountTotal.Balance - 60000) + "\nPlease retype"); } else { _model.WithdrawalBalance(amount, anumber); h.AccountNumber = anumber; h.Type = 1; h.Amount = amount; h.TradingAcountNumber = "1"; _history.HinsertBalance(h); Console.WriteLine("The amount you have withdrawn is " + amount + " (VNĐ)"); } } }