• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Custom High and Low in indicator panel. How to fill in?

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

    Custom High and Low in indicator panel. How to fill in?

    Hi,

    Hopefully I can get some assistance with the following.

    I have a custom indicator in real time plotting a line for the high and a low for each bar, the problem I'm having is how do I fill the space in between the high and low? I just can't seem to find how to do this. If I use a Bar instead of a Line then every bar starts at zero.

    Appreciate your help.
    suprsnipes.

    #2
    Hello suprsnipes,


    You could use DrawRegion() to accomplish this.
    Here is the DrawRegion() Help Guide to assist you further.
    I have included below an example of how to use DrawRegion().
    Code:
    protectedoverride void Initialize()
    { Add( new Plot(Color.FromKnownColor(KnownColor.Orange), PlotStyle.Line, "Hi" )); Add( new Plot(Color.FromKnownColor(KnownColor.Green), PlotStyle.Line, "Lo" )); Overlay = true ; } protectedoverride void OnBarUpdate() { Hi.Set(High[ 0]); Lo.Set(Low[ 0]); DrawRegion( "tag1" , CurrentBar, 0 ,Hi, Lo, Color.Empty, Color.Purple, 2 );
    }

    Shawn B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by tvaughan4, 12-13-2019, 10:46 PM
    2 responses
    16 views
    0 likes
    Last Post tvaughan4  
    Started by digibob, 12-13-2019, 10:01 PM
    3 responses
    12 views
    0 likes
    Last Post digibob
    by digibob
     
    Started by ldissinger, Yesterday, 12:55 PM
    1 response
    19 views
    0 likes
    Last Post ldissinger  
    Started by pstrusi, Yesterday, 09:06 AM
    1 response
    27 views
    0 likes
    Last Post marcus2300  
    Started by vpzdcv, Yesterday, 02:31 AM
    0 responses
    13 views
    0 likes
    Last Post vpzdcv
    by vpzdcv
     
    Working...
    X