public void DepositMoney(object sender, DepositArgs args) { foreach (DepositAccount ba in clients) { if (ba.GetAccountid == args.get_accountid) { ba.MakeDeposit(args.get_amount); } } }
public void CheckAccount(object sender, DepositArgs args) { foreach (DepositAccount ba in clients) { if (ba.GetAccountid == args.get_accountid) { if (ba.getwithdrawrequest == true) { clients.Remove(ba); } } } }