IB ActiveX control rejects orders of certain prices?

Discussion in 'Interactive Brokers' started by echo, Feb 22, 2002.

  1. echo


    I’m wondering if anyone else is having the following problem?

    I have the TWS ActiveX control integrated into my program. It connects to TWS just fine, and in general communicates just fine. The problem is that some limit orders are rejected and it appears to be linked to certain prices.

    For example, a buy order with a limit price of 27.50 is accepted. A limit order with a price of 27.56 is rejected (it shows up in the TWS screen, but is immediately cancelled by the system and a message box appears that says “Order rejected – Unknown reason”). I tested with various other prices, such as 30.00 worked while 3.03 didn’t (although 30.01 did IIRC).

    My only guess is that it possibly has something to do with float imprecision? The only thing changed in any of the orders (other than the order ID) was the price. None of the orders crossed the market. I tested the prices both with my application as well as with the Active X test program supplied by IB.

    Anyway have similar issues?
  2. echo


    BTW, this doesn’t appear to be a problem when using DDE instead of the ActiveX control.
  3. jwcrim


    Demo TWS or real account TWS?
    Applet TWS or standalone TWS?
    Time of Day?
  4. echo


    I've tried with several symbols, but mainly QCOM on my personal account (i.e. not the demo). I don't recall if I tested any NYSE or AMEX. This was with the standalone app. I have tried at many different times throughout the day over the course of several days, all with the same results.

    I contacted IB tech support and they mentioned someone else had also experienced this problem.
  5. jwcrim


    I assume you are using BEST EXECUTION when entering the orders.

    I'm using ActiveX from a vb app.

    I tried running your numbers using the DEMO applet TWS and get the same results as you do regardless of what symbol I use. I'll try my account TWS tomorrow.
  6. echo


    That is correct. I am able to transmit orders of certain prices, but the EXACT same trade with another price (and new id of course) will fail. I have followed all documentation, used all the sample apps they provided, etc., all with the same results. The exceptions are that the orders that fail via ActiveX or sockets, are accepted via DDE or if entered directly into TWS manually. I am fairly certain I am not doing anything incorrect. Not that I haven't been wrong before. :p
  7. echo


    Thanks jwcrim. It is nice to have some confirmations that I am not losing my mind. It is my guess that it must be something in the socket API implementation code in TWS since I'm guessing the ActiveX control is using the sockets API, while the DDE link wouldn't be using the sockets API.
  8. jwcrim


    ActiveX with vb app.
    IB's applet TWS
    Windows 2000

    Live orders:

    QQQ BUY LMT 100 30.03 BEST (error)
    QQQ BUY LMT 100 30.02 BEST (OK)
    INTC SELL LMT 1 30.03 BEST (error)
    INTC SELL LMT 1 30.02 BEST (OK)
    MSFT BUY LMT 1 30.03 BEST (error)
    MSFT BUY LMT 1 30.02 BEST (OK)

    Error Message: "Order rejected - Unknown reason"

    The same (30.03) orders that resulted in the error message, went through if you manually entered them on the Excel page.

    The 30.03 price is an example - there are many other price values that always result in an error.

    Any word from IB on this?
  9. echo


    Any word from IB on this?

    No. I haven't heard anything back from IB yet, though I only reported it Friday afternoon. Maybe you should report it as well just to be sure IB knows it is happening to more than one or two people.

    I was all ready to start using my app this week, but I guess it looks like I'll have to wait for a fix.
  10. jwcrim


    There is a new TWS.ocx dated 2/25/2002 1:19 PM

    I downloaded the whole works again and a quick test with the 30.03 price was successful. It appeared to be a change in the ocx rather than a change in the TWS.

    Let me know what you find.
    #10     Feb 25, 2002