Пример #1
0
        public TerminalDataset GetTerminals()
        {
            //Get a list of Argix terminals
            TerminalDataset            terminals = new TerminalDataset();
            FreightAssignServiceClient client    = new FreightAssignServiceClient();

            try {
                DataSet ds = client.GetTerminals();
                if (ds != null)
                {
                    terminals.Merge(ds);
                }
                client.Close();
            }
            catch (TimeoutException te) { client.Abort(); throw new ApplicationException(te.Message); }
            catch (FaultException fe) { client.Abort(); throw new ApplicationException(fe.Message); }
            catch (CommunicationException ce) { client.Abort(); throw new ApplicationException(ce.Message); }
            return(terminals);
        }