Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Execute order X amount of bars after price crosses line

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

    Execute order X amount of bars after price crosses line

    Hi there,

    In the attached example, I would like to trigger a short order when the blue dot appears. The blue dot can be targeted by a postive numeric value - however I am trying to refine this criteria to only if price has crossed over/under the blue supertrend line X amount of bars ago.

    For this example the strategy would simply be: enter short on Dot trigger if high has crossed above Supertrend 10 bars ago.

    Thanks for any help. I was messing in the strategy builder but could not get this triggered correctly.


    Attached Files

    #2
    Hello quicksandatl,

    Thank you for your post.

    We have an existing sample Strategy Builder script that demonstrates counting x number of bars after an event occurs, ExampleBarCounter.

    You can find the file for download at the link below as well as an explanation of how the script works:



    Please let us know if you have any further questions.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    43 views
    0 likes
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    21 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    30 views
    1 like
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    50 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    40 views
    0 likes
    Last Post CarlTrading  
    Working...
    X