IB API order issue.

Discussion in 'Automated Trading' started by walterjennings, May 3, 2007.

  1. I was wondering if anyone has ran into this problem with using the TWS c++ API.

    This morning my automated application attempted to place an order, the order was received by TWS but did not automatically transmit to IB, and ended up sitting there with the transmit button showing instead of going through like usual.

    Has anyone run into this problem? or a solution? this is the first time this has happened to the system in the last 4 months of trading this app.
     
  2. sprstpd

    sprstpd

    This is probably a stupid question, but do you have the "Reuse rejected order" checkbox enabled (under Configure-->Order)?
     
  3. ya its checked. im not sure if the order was rejected or not. it looks like it arrived in TWS and just sat there.
     
  4. Bob111

    Bob111

    you need to be more specific about this order. if it's stock,routed to ISLAND in morning,before open-there is been some issues today.
     
  5. it was a forex order on ideal pro. there is no record of the order in the audit report. i ended up closing my app and cancelling the untransmitted order manually.
     
  6. There should be a flag in your Order class, something called transmit, you need to set transmit to true to transit your order out. I am using Java, and I believe C++ should have the same kind stuff.
     
  7. i guess this could be the problem. i was'nt setting this variable, but iv never had a problem before with it not transmitting. maybe the order object does'nt intialize the variables.
     
  8. I have just checked the order class, the member should be transmit.
     
  9. sprstpd

    sprstpd

    Check your audit trail to see if it provides any clues. If you have that flag on (reuse rejected orders) and one of your orders gets rejected for some reason, you will experience just what you described, namely an untransmitted order that looks exactly like the order you intended to submit.
     
  10. Bob111

    Bob111

    you should get some respond from API to your app. thru order status event or error.
    also-IB constantly make changes that may affect your order. i'm not expert in forex, but in stocks such thing may happends for example if you did not specify currency for stock OR you submit your orders using different type of variables. single unstead of double for example
     
    #10     May 3, 2007