Example #1
0
        override public decimal GetAccountBalance(string accountNumber)
        {
            if (!_isExistingCustomer)
            {
                throw new Exception("Account Balance may only be obtained for an existing customer");
            }

            if (string.IsNullOrEmpty(accountNumber))
            {
                throw new ArgumentNullException("accountNumber");
            }

            // send the name, and account number, note that was we should only be
            // providing correct names and numbers, we are not going to catch any exceptions!
            //_clientContextObj.DeleteContext("CONNTYPE", ref _contextArray);
            _clientContextObj.ConnectionUsage = ConnectionTypes.NonPersistent;
            return(_Handler.GetBalance(_name, accountNumber, ref _clientContextObj));
        }