Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Stop drawing once price closes above/below a line

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

    Stop drawing once price closes above/below a line

    Hi guys

    I have recently compiled a simple indicator that plots a mid-point line (DrawLine()). Is there a way I can make the line to stop once price crosses and closes above it? I attached a picture to show what I'm talking about

    Thanks!
    Vladi
    Attached Files

    #2
    Hello,

    Thank you for the question.

    It would be easiest to see what you have already put in place to provide a suggestion, there are a few different ways you could check that the price has crossed.

    To start with, if you are currently using the Price series to draw the line, you could likely use the same series to check a CrossAbove or CrossBelow for a price value:



    This could additionally be accomplished by checking conditions and using variables, again it would be better to see what you currently have and recommend something based on that.

    I look forward to being of further assistance.

    Comment


      #3
      Originally posted by Scalper85 View Post
      Hi guys

      I have recently compiled a simple indicator that plots a mid-point line (DrawLine()). Is there a way I can make the line to stop once price crosses and closes above it? I attached a picture to show what I'm talking about

      Thanks!
      Vladi
      Exact question answered here, with the relevant code posted.

      ref: http://ninjatrader.com/support/forum...78&postcount=1

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Mindset, Today, 06:46 AM
      0 responses
      9 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by M4ndoo, Yesterday, 05:21 PM
      0 responses
      14 views
      0 likes
      Last Post M4ndoo
      by M4ndoo
       
      Started by M4ndoo, 04-19-2026, 05:54 PM
      0 responses
      15 views
      0 likes
      Last Post M4ndoo
      by M4ndoo
       
      Started by cmoran13, 04-16-2026, 01:02 PM
      0 responses
      82 views
      0 likes
      Last Post cmoran13  
      Started by PaulMohn, 04-10-2026, 11:11 AM
      0 responses
      48 views
      0 likes
      Last Post PaulMohn  
      Working...
      X