• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Cancelled expired order Stop Loss

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

    Cancelled expired order Stop Loss

    Hi,

    the stop loss and profit targets are being cancelled after my order is filled.

    I am placing the entries using a script with this code:

    DoubleLossTicks = 6;
    DoubleProfitTicks = 9;
    OrderName = "EnterShortCrossBelowReEnter";

    SetStopLoss(OrderName, CalculationMode.Ticks, DoubleLossTicks, false);
    SetProfitTarget(OrderName, CalculationMode.Ticks, DoubleProfitTicks+10);
    EnterShort( 0, contracts, OrderName);


    trading with minute bars on bar close.
    Time in force set to GTC.

    #2
    Hello JesseCulver,

    Thanks for your post.

    I don't see anything obvious from the code you have provided.

    Please send me your log and trace files so that I may look into what occurred.

    You can do this by going to the Control Center-> Help-> Mail to Platform Support.

    Ensuring 'Log and Trace Files' is checked will include these files. This is checked by default.

    Please reference the following in the subject line: Atten:Paul and a link to this thread.
    Paul H.NinjaTrader Customer Service

    Comment


      #3
      Hi Paul,

      thank you for replying.
      I emailed the log and trace files as requested.
      Also included my script for reference.

      I noticed it is only happening when I have an additional data series defined in my script using the AddDataSeries.

      thanks,
      Jesse

      Comment


        #4
        Turns out the difference is running with OnBarClose vs OnEachTick.

        I am able to make my script work and not work based on switching that.

        Comment


          #5
          There was a bug identified in multi-series scripts which impacted these Set methods. It will be fixed in the next release and tracked using ID # 10342
          MatthewNinjaTrader Product Management

          Comment


            #6
            Thank you.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by ralett, Today, 11:52 AM
            0 responses
            4 views
            0 likes
            Last Post ralett
            by ralett
             
            Started by rtwave, Yesterday, 07:06 PM
            1 response
            22 views
            0 likes
            Last Post NinjaTrader_PaulH  
            Started by DTSSTS, Today, 11:27 AM
            1 response
            4 views
            0 likes
            Last Post NinjaTrader_ChelseaB  
            Started by siroya, Today, 10:02 AM
            2 responses
            9 views
            0 likes
            Last Post DTSSTS
            by DTSSTS
             
            Started by pjsmith, Today, 10:50 AM
            0 responses
            9 views
            0 likes
            Last Post pjsmith
            by pjsmith
             
            Working...
            X