Пример #1
0
 void StartRequest()
 {
     connect_status = skq.SKQuoteLib_RequestTicks(1, stockNo);
     if (connect_status == 0)
     {
         msg_update(stockNo + " 成交明細與五檔設置成功");
     }
     else
     {
         msg_update("成交明細與五檔錯誤代碼: " + Convert.ToString(connect_status));
     }
 }
Пример #2
0
        void RegisterQuote()
        {
            short sPage       = 1;
            var   symbolCodes = symbolIndexCode.Values;

            foreach (var code in symbolCodes)
            {
                m_nCode = m_SKQuoteLib.SKQuoteLib_RequestTicks(sPage, code);
                if (m_nCode != 0)
                {
                    throw new SourceException();
                }
                sPage++;
            }
        }
Пример #3
0
        private void btnTicks_Click(object sender, EventArgs e)
        {
            deleteTickData();
            listTicks.Items.Clear();
            m_dtBest5Ask.Clear();
            m_dtBest5Bid.Clear();
            GridBest5Ask.DataSource = m_dtBest5Ask;
            GridBest5Bid.DataSource = m_dtBest5Bid;

            GridBest5Ask.Columns["m_nAskQty"].HeaderText = "張數";
            GridBest5Ask.Columns["m_nAskQty"].Width      = 60;
            GridBest5Ask.Columns["m_nAsk"].HeaderText    = "賣價";
            GridBest5Ask.Columns["m_nAsk"].Width         = 60;

            GridBest5Bid.Columns["m_nAskQty"].HeaderText = "張數";
            GridBest5Bid.Columns["m_nAskQty"].Width      = 60;
            GridBest5Bid.Columns["m_nAsk"].HeaderText    = "買價";
            GridBest5Bid.Columns["m_nAsk"].Width         = 60;

            m_nCode = SKQuoteLib.SKQuoteLib_RequestTicks(0, txtTick.Text.Trim());

            SendReturnMessage("Quote", m_nCode, "SKQuoteLib_RequestTicks");
        }
Пример #4
0
        private void btnTickStop_Click(object sender, EventArgs e)
        {
            m_nCode = SKQuoteLib.SKQuoteLib_RequestTicks(50, txtTick.Text.Trim());

            SendReturnMessage("Quote", m_nCode, "SKQuoteLib_CancelRequestTicks");
        }