Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Get color of background on a specific bar

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

    Get color of background on a specific bar

    Hello guys,

    I have an indicator that changes the background color on a specific bar in specific conditions. Which code could help me to get the color code of that specific background color when the indicator changes it? I'm testing with BackBrushes[0] but no luck so far.

    Thank you.

    #2
    Hello facuevasm,

    If the indicator is coloring bars and you are trying to access those colors from outside of the indicator there is not a way to do that. BarBrushes is only available to the script that sets it. The indicator would need to instead expose a signal in the form of a Plot.

    I the indicator in question something which you have the code for or is this a third party item? If you have the code for it you can add a plot and then expose a signal by plotting in the areas of the code which currently are setting the BackBrush.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment


      #3
      Hello,

      thank you for your reply. my mistake, what I need is the background color. I'm using BackBrushes[0].

      I will be alert!

      Kind regards,

      Felipe

      Comment


        #4
        Hello facuevasm,

        The background color is not something which a script can read. If your indicator sets a background color another indicator cannot read that. The indicator which sets the background needs to expose the data as a plot for it to be used as a signal.

        I look forward to being of further assistance.
        JesseNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by aligator, Today, 02:09 PM
        1 response
        9 views
        0 likes
        Last Post NinjaTrader_Kate  
        Started by patpat, Today, 11:34 AM
        1 response
        6 views
        0 likes
        Last Post NinjaTrader_ChrisL  
        Started by crystalet, Today, 10:41 AM
        3 responses
        14 views
        0 likes
        Last Post crystalet  
        Started by tonynt, Today, 10:47 AM
        3 responses
        15 views
        0 likes
        Last Post NinjaTrader_ChrisL  
        Started by punkiy2111, Today, 09:56 AM
        1 response
        14 views
        0 likes
        Last Post NinjaTrader_ChristopherD  
        Working...
        X