示例#1
0
        public static void InitializeEbay()
        {
            GetApiContext();

            if (ActiveList == null)
            {
                ActiveList = new ItemTypeCollection();
            }

            if (SoldList == null)
            {
                SoldList = new OrderTransactionTypeCollection();
            }

            if (_timer == null)
            {
                //_timer = new DispatcherTimer(TimeSpan.FromMinutes(1), DispatcherPriority.Background,
                //    RefreshEbayData, Dispatcher.CurrentDispatcher);
                //_timer.Start();
            }
        }
示例#2
0
        private static void RefreshEbayData(object sender, EventArgs eventArgs)
        {
            var apicall = new GetMyeBaySellingCall(_apiContext);

            apicall.ActiveList      = new ItemListCustomizationType();
            apicall.ActiveList.Sort = ItemSortTypeCodeType.EndTime;
            apicall.SoldList        = new ItemListCustomizationType();
            apicall.SoldList.Sort   = ItemSortTypeCodeType.EndTime;

            apicall.ActiveList.Pagination = new PaginationType {
                EntriesPerPage = 100
            };
            apicall.SoldList.Pagination = new PaginationType {
                EntriesPerPage = 100
            };

            apicall.GetMyeBaySelling();

            ActiveList = apicall.ActiveListReturn.ItemArray;
            SoldList   = apicall.SoldListReturn.OrderTransactionArray;
        }
示例#3
0
        private static void RefreshEbayData(object state)
        {
            //eBayAPIInterfaceService faf = new eBayAPIInterfaceService();
            //faf.SoapRequest
            var apicall = new GetMyeBaySellingCall(_apiContext);

            apicall.ActiveList      = new ItemListCustomizationType();
            apicall.ActiveList.Sort = ItemSortTypeCodeType.EndTime;
            apicall.SoldList        = new ItemListCustomizationType();
            apicall.SoldList.Sort   = ItemSortTypeCodeType.EndTime;

            apicall.ActiveList.Pagination = new PaginationType {
                EntriesPerPage = 500
            };
            apicall.SoldList.Pagination = new PaginationType {
                EntriesPerPage = 500
            };

            apicall.GetMyeBaySelling();

            ActiveList = apicall.ActiveListReturn.ItemArray;
            SoldList   = apicall.SoldListReturn.OrderTransactionArray;
        }