Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

GTC versus Day

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    GTC versus Day

    Hi,

    I've been running my strategies on some new instruments and exchanges. In particular, today I ran on SB (sugar on ICE) and received a rejected order because it appears that strategies, by default, submit GTC orders which ICE won't accept.

    So, looking at the Ninja help guide, I find this....


    protected override void Initialize()
    {
    TimeInForce = Cbi.TimeInForce.Day;
    }

    If I add this bit of code, will that likely upset all the other instruments/exchanges that are currently working just fine? I do trade both RTH and through the night. Would it perhaps be best if I had a separate script for the ICE products? (which I'd much prefer NOT to do).

    Thanks.

    #2
    Hello coolmoss,

    It should not upset any other instruments besides changing the TimeInForce for your orders. Note that you can check the name of the instrument to filter a settings for a specific instrument if you would like. For example:

    Code:
    if( Instrument.MasterInstrument.Name == "SB")
    {
    	//do something
    }
    You may read more about MasterInstrument at the following link.
    http://www.ninjatrader.com/support/h...trument_na.htm

    Please let me know if I can be of further assistance.
    JCNinjaTrader Customer Service

    Comment


      #3
      Great suggestion!

      Thanks so much.

      Comment


        #4
        Hello coolmoss,

        Your welcome.

        Let us know if we can be of further assistance.
        JCNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by SalmaTrader, 07-07-2026, 10:26 PM
        0 responses
        50 views
        0 likes
        Last Post SalmaTrader  
        Started by CarlTrading, 07-05-2026, 01:16 PM
        0 responses
        22 views
        0 likes
        Last Post CarlTrading  
        Started by CaptainJack, 06-17-2026, 10:32 AM
        0 responses
        16 views
        0 likes
        Last Post CaptainJack  
        Started by kinfxhk, 06-17-2026, 04:15 AM
        0 responses
        22 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Started by kinfxhk, 06-17-2026, 04:06 AM
        0 responses
        23 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Working...
        X