Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Quick Question - Color Disappears on Reload

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

    Quick Question - Color Disappears on Reload

    My range bar close marker draws two lines at the projected closes of the current range bar. I have these colored using:

    private Color markercolor = Color.Blue;

    DrawLine("upper",false,-1,upper,1,upper,markercolor,DashStyle.Solid,thickness)

    This works fine when I add it to a chart initially. But say I close NT down, and then open it up again, the color is now gone. I click into indicators from the chart, and the place to choose the color is just blank.

    Any ideas? I'm sure there is a simple something I'm forgetting...

    Thanks -

    #2
    You're using colors as inputs?

    You need to serialize them perhaps?

    http://www.ninjatrader.com/support/f...ead.php?t=4977

    That's the only thing I can think of at the moment.


    Originally posted by jmflukeiii View Post
    My range bar close marker draws two lines at the projected closes of the current range bar. I have these colored using:

    private Color markercolor = Color.Blue;

    DrawLine("upper",false,-1,upper,1,upper,markercolor,DashStyle.Solid,thickness)

    This works fine when I add it to a chart initially. But say I close NT down, and then open it up again, the color is now gone. I click into indicators from the chart, and the place to choose the color is just blank.

    Any ideas? I'm sure there is a simple something I'm forgetting...

    Thanks -

    Comment


      #3
      Excellent thank you. All fixed up -

      You do seem surprised that I did it this way. Is there a better way to have done it? I though about plots set to hash, but I only care about the current bar, and don't want the plots to plot in the past.
      Last edited by jmflukeiii; 04-04-2013, 09:22 PM.

      Comment


        #4
        jmflukeiii, same you would have to do for a custom color used as input for a plot. You could call .Reset on those to then only set a value on for specific bars, but I think your approach is just fine.
        BertrandNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by ntbone, Yesterday, 11:42 PM
        1 response
        13 views
        0 likes
        Last Post NinjaTrader_PaulH  
        Started by mr_trade, 11-26-2020, 05:01 PM
        5 responses
        59 views
        0 likes
        Last Post mr_trade  
        Started by evanp90, 01-14-2021, 07:03 PM
        4 responses
        33 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by fernlicht, Today, 04:01 AM
        1 response
        8 views
        0 likes
        Last Post NinjaTrader_Jason  
        Started by Leeroy_Jenkins, Today, 03:51 AM
        1 response
        14 views
        0 likes
        Last Post Leeroy_Jenkins  
        Working...
        X