Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Stop Orders on Tick Charts

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

    Stop Orders on Tick Charts

    I have a strategy that works fine on minute bars. However, when I run it on tick bars my stops quit working. I am handling my own stops and not using Ninja's SetStopLoss function. This is an example of my code. Any idea why it wouldn't function on tick bars?

    Code:
    if (Positions[0].MarketPosition==MarketPosition.Short)
    {
    stopprice=Math.Max(Highs[1][0],Highs[1][1]);
    ExitShortStop(stopprice);
    }

    #2
    Hello,

    From the code you posted, I do not see anything wrong. Maybe you could post more of the code so we can assist? Also, make sure your secondary bar object is receiving data.

    Are there any errors in your Control Center logs?
    DenNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by cmtjoancolmenero, 04-25-2024, 03:58 PM
    19 responses
    106 views
    0 likes
    Last Post cmtjoancolmenero  
    Started by nleitman, Yesterday, 11:46 AM
    10 responses
    28 views
    0 likes
    Last Post nleitman  
    Started by ccbiasi, 11-23-2017, 06:06 AM
    6 responses
    2,216 views
    0 likes
    Last Post NinjaTrader_LuisH  
    Started by Pattontje, Yesterday, 11:54 PM
    1 response
    5 views
    0 likes
    Last Post NinjaTrader_LuisH  
    Started by Pattontje, Today, 12:10 AM
    1 response
    4 views
    0 likes
    Last Post NinjaTrader_Erick  
    Working...
    X