Exemplo n.º 1
0
        /// <summary>
        /// use stub to test existance of a PriceList via web services
        /// </summary>
        /// <param name="PriceListPaths">PriceLists to check, Array of paths</param>
        /// <returns>ArrayList of TExists_Return</returns>
        public ArrayList exists(string[] PriceListPaths)
        {
            TExists_Return[] PriceLists_out = stub.exists(PriceListPaths);

            ArrayList result = new ArrayList();

            for (int i = 0; i < PriceLists_out.Length; i++)
            {
                TExists_Return PriceList_out = PriceLists_out[i];

                if (PriceList_out.Error == null)
                {
                    Console.WriteLine("successfully checked if PriceList exists: " + PriceList_out.Path);
                    result.Add(PriceList_out);
                }
                else
                {
                    Console.WriteLine("an error occured (Epages Error):\n" + PriceList_out.Error.Message);
                }
            }

            return(result);
        }