Exemplo n.º 1
0
 private void appStatusBW_DoWork(object sender, DoWorkEventArgs e)
 {
     try
     {
         getAppUpdate();
         // UpdateChat(false);
         ordersListView.BackColor = Color.White;
     }
     catch (Exception ex)
     {
         ordersListView.BackColor = Color.Red;
         _updateApp1 = false;
         service     = new AlsiWebService.AlsiNotifyService();
     }
 }
Exemplo n.º 2
0
        private void SendTEST()
        {
            bool Matched = true;
            var  t       = new AlsiUtils.Trade()
            {
                TimeStamp      = DateTime.Now,
                BuyorSell      = Trade.BuySell.Buy,
                InstrumentName = "Test",
                TradedPrice    = 34465,
                TradeVolume    = 1,
            };


            var o = new AlsiWebService.xlTradeOrder();

            if (t.BuyorSell == Trade.BuySell.Buy)
            {
                o.BS = AlsiWebService.BuySell.Buy;
            }
            if (t.BuyorSell == Trade.BuySell.Sell)
            {
                o.BS = AlsiWebService.BuySell.Sell;
            }
            o.Timestamp = t.TimeStamp;
            o.Volume    = t.TradeVolume;
            o.Price     = t.TradedPrice;
            o.Contract  = t.InstrumentName;
            o.Status    = Matched ? AlsiWebService.orderStatus.Completed : AlsiWebService.orderStatus.Ready;
            service.InsertNewOrder(o);
            var s = new AlsiWebService.AlsiNotifyService();

            s.InsertNewOrder(o);

            if (t.Reason == Trade.Trigger.CloseLong || t.Reason == Trade.Trigger.CloseLong)
            {
                WebSettings.General.MANUAL_CLOSE_TRIGGER = true;
            }
        }
Exemplo n.º 3
0
        private void SendTEST()
        {
            bool Matched = true;
            var t = new AlsiUtils.Trade()
            {
                TimeStamp = DateTime.Now,
                BuyorSell = Trade.BuySell.Buy,
                InstrumentName = "Test",
                TradedPrice = 34465,
                TradeVolume = 1,

            };


            var o = new AlsiWebService.xlTradeOrder();
            if (t.BuyorSell == Trade.BuySell.Buy) o.BS = AlsiWebService.BuySell.Buy;
            if (t.BuyorSell == Trade.BuySell.Sell) o.BS = AlsiWebService.BuySell.Sell;
            o.Timestamp = t.TimeStamp;
            o.Volume = t.TradeVolume;
            o.Price = t.TradedPrice;
            o.Contract = t.InstrumentName;
            o.Status = Matched ? AlsiWebService.orderStatus.Completed : AlsiWebService.orderStatus.Ready;
            service.InsertNewOrder(o);
            var s = new AlsiWebService.AlsiNotifyService();
            s.InsertNewOrder(o);

            if (t.Reason == Trade.Trigger.CloseLong || t.Reason == Trade.Trigger.CloseLong) WebSettings.General.MANUAL_CLOSE_TRIGGER = true;
        }
Exemplo n.º 4
0
 private void appStatusBW_DoWork(object sender, DoWorkEventArgs e)
 {
     try
     {
         getAppUpdate();
        // UpdateChat(false);
         ordersListView.BackColor = Color.White;
     }
     catch (Exception ex)
     {
         ordersListView.BackColor = Color.Red;
         _updateApp1 = false;
         service = new AlsiWebService.AlsiNotifyService();
     }
 }