Programs to interact w/ IB TWS API & place trades

Discussion in 'Automated Trading' started by jtnet, Nov 9, 2006.

  1. Hi,

    I am not familiar with APIs, but wanted to know if there is a possibility to a place bracket orders automatically with only entering a price. The orders then will appear in TWS.

    For example:

    I want to generate a bracket order for the emini SPX future (ESH7) with predifined parameters (+-6) from an entered price. For ESH7
    will be + - 6pts from the entered price (1400).

    1) The API will ask me a price for the ESH7
    2) I type in 1400
    3) the Api generates the follwoing orders:

    Buy ESH7 @ 1394.00
    Sell ESH7 @ 1396.00 (bracket order)

    Sell ESH7 @ 1406.00
    Buy ESH7 @ 1404.00 (bracket order)

    I do not want the stop loss of the bracket order.Is this possible?
    How should I do it with VBA, java? Could someone show me the correct path...

    Regards

    JB
     
    #21     Mar 5, 2007
  2. Chuck_T

    Chuck_T eSignal

    Check out QuoteTrader which works with IB and multiple datafeeds at the same time.

    The new version with real time charting will be put into beta in a few weeks.

    It is free supported by the Quote.com web site.

    Chuck

    http://www.esignal.com/quotetrader
     
    #22     Mar 5, 2007
  3. kowboy

    kowboy

    How are you coming along with the progress on Quote Trader?
     
    #23     Apr 14, 2007
  4. You can use the TWSLink DLL to control TWS from any scripting language that supports DLLs. It works with esignal, tradestation, wealthlab, and others.

    http://www.trade-commander.org/
     
    #24     Apr 14, 2007
  5. Chuck_T

    Chuck_T eSignal

    kowboy,

    The new free version of QuoteTrader is available now with real time charts using IB's datafeed and trading interface.

    Works with multiple brokerage feeds at the same time like Ameritrade. Check it out:

    http://pmd.esignal.com/quotetrader/

    Chuck
     
    #25     Apr 24, 2007
  6. Hi All,

    I'm looking into getting TradeStation to interface with IB (i.e. send orders to an IB account) and TWSlink seems to be able to do this. Before I go further and start trying to code something, can someone explain what is required to do this correctly? The TWSlink website has the following code example for TS:

    If MarketPosition = 0 Then begin
    If Sig < 0 Then begin { section 1.1 }
    Sell ("MR_SE") This Bar on Close;
    if Timeout = 0 then begin
    Print("pos before short: "+NumToStr(GET_POSITIONS(UidContract,""),0));
    CUSTOMCOMMENT("Enter Short",0);
    { place sell order, dont transmit to IB}
    Oid1=PLACE_ORDER(UidContract,0,"SELL","MKT",OrderSize,0.0,0.0,"GTC",0,-1,"","",-1);

    The above would be something I'd write into my strategy, no? I'd want to replace my orders with PLACE_ORDER calls along with the associated position check?

    Thanks in advance for any help.

    Regards,

    Mike
     
    #26     Nov 11, 2007
  7. Tums

    Tums

  8. i thought all the contestants did their own code, I never thought they could use commercial applications to

    "The Olympiad is open to any undergraduate or graduate student* with programming experience. Trades must be generated by computer algorithms. Students will compete using the same Interactive Brokers' Trader Workstation Application Program Interface (API) that professional traders use to create automated trading solutions. A multitude of programming languages including Java, C++, C, and Visual Basic may be utilized with our API. Student-created algorithms may trade US stocks, options, futures, Forex, or bonds as often as their programs require over the contest period and must make at least 25 trades."

    http://www.interactivebrokers.com/en/general/education/IBTradingOlympiad.php
     
    #28     Nov 17, 2007
  9. is it just me or anyone else here think vstudio is junk compared to it's cost?

    just like their OS, they are making billions yet their OS is only worth a fraction of that cost
     
    #29     Nov 17, 2007