Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Drawn Horizontal Line with price marker?

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

    Drawn Horizontal Line with price marker?

    When my indicator draws a horizontal line I would like it to also "issue" a price marker where that line is at. As the line is drawn and not based on a plot I can't see how to get that done.

    {
    DrawLine("SLup", false, 0, Low[0], 1, Low[0], upColor, DashStyle.Solid, 2);
    }

    This line is drawn only when my conditions are fulfilled. When the conditions change, the line disappears and I would like the price marker to then also disappear.

    Is there a way to accomplish that?

    sandman

    #2
    Hello sandman,

    A price marker can only be created by a plot using documented methods.

    Create a plot, set the pen of the plot to the color you want the marker to appear. Optionally, set each bars PlotColors to Color.Empty to hide the line on the chart but still show the marker.

    When you want the marker to disappear, set the pen color to Color.Transparent.

    PlotColors - http://ninjatrader.com/support/helpG...plotcolors.htm
    Plots - http://ninjatrader.com/support/helpGuides/nt7/plots.htm
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

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