Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Fractal Above/Below Horizontal Line

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

    Fractal Above/Below Horizontal Line

    Hello Support, Im trying to make an indicator that checks if price has turned above/below a manually drawn Horizontal Line, something like:

    (W/Renko Candles)

    if ( (Close[3] < Close[2] && Close[2]> Close[0]) && Close[0] >hLine.Y ) && FirstTickOfBar ) // Renko Fractal Down
    {

    Alert goes off

    }

    just making sure this approach is the correct one, how do i check for Hlines? is the generic "hLine.Y" ok? , just need one Horizontal Line on the chart.

    Thank you!


    #2
    Hello kabott, thanks for your post.

    You may use the DrawObjects collection to get a specific horizontal line. See the example on this page, specifically Example #3, "Looping through the collection to find specific draw objects"


    Once you get the draw object assigned, you can reference the horizontal line's properties. Here is the documentation on the IHorizontalLine object:



    Best regards.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 03-31-2026, 09:41 PM
    1 response
    129 views
    1 like
    Last Post NinjaTrader_ChelseaB  
    Started by CarlTrading, 04-01-2026, 02:41 AM
    0 responses
    74 views
    1 like
    Last Post CarlTrading  
    Started by CaptainJack, 03-31-2026, 11:44 PM
    0 responses
    116 views
    2 likes
    Last Post CaptainJack  
    Started by CarlTrading, 03-30-2026, 11:51 AM
    0 responses
    110 views
    1 like
    Last Post CarlTrading  
    Started by CarlTrading, 03-30-2026, 11:48 AM
    0 responses
    89 views
    0 likes
    Last Post CarlTrading  
    Working...
    X