Need help with IB's excel API

Discussion in 'Trading Software' started by rolando87, Apr 6, 2011.

  1. Hi folks,

    Basically i'm looking for something like excel to be able to create orders and send them through IB's API. I looked into IB's excel activeX package but its currently driving me nuts as I can't seem to edit anything, and any time i do so, it gives me a message "TWS Control is not initialized" and I have to restart the program. Basically I'm trying to edit the stuff in VBA and when I touch anything that message comes up.

    Basically if i could create orders using whatever simple algorithm i create in excel would work just fine.

    If anyone has any other suggestions for programs I can download I'd very much appreciate it. Or if anyone has a simple excel version that can easily connect to the API that would be great.

    Thanks in advance.
  2. Bob111


    DDE is one thing that will allow you to do whatever. easier than API
    before you do anything with API you must properly install it and add to your application.
    better place to ask this kind of questions is TWSAPI yahoo group. there is probably a ton of examples too.

    not sure what you trying to edit..
  3. Thanks for your response.

    There is the DDE excel that came with the IB download package. Is that what you are referring to. Because it basically looks very similar to the ActiveX excel. I have no idea what the difference is.

    Also, i did download the API package from the IB website, it came with the excel both DDE and ActiveX. Is this what you meant by properly installing it on my application?

    And I was jsut trying to edit and cleanup the excel sheet because its filled with usless cells and crap I don't even need like multiplier, strike etc. I jsut want to take whats there and move stuff around and combine multiple sheets into one sheet so I'm not constantly moving around. A lot of it will involve touching the VBA code and that's where the problem arises.

    Is it not possible to edit their excel VBA code?
  4. Bob111


  5. Use the Excel DDE.
    It's all in the user doc DDE for Excel:
    Your TWS must be open for the API to work and you must also set it up. It's all well explained in there.
    If you can't make it work, consider not doing it because it may mean that you have no idea what you are doing. Remember that the logic that you are going to code or the formulas that you are going to write may have bugs. When the program is on and it fires orders it's real money... up or down.
    Good luck.