Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Draw Region question

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

    Draw Region question

    Hello,
    I'm trying to create an indicator that will change the color between the MA's based on conditions. I can't figure out how to "turn off" the conditions. As a result the colors are getting blended. Can anyone offer me a suggestion? Thanks.

    Code:
    if (VMAZones(9, 2, 18).Upper[0] > RSChannel(9, 1.5, 3, 14, 10).Mid[0])
                {
                    DrawRegion("Holding Up" , CurrentBar, 0, VMAZones(9, 2, 18).Upper, VMAZones(9, 2, 18).Lower, Color.Black, Color.Lime, 2);
                }
               
                
                if (VMAZones(9, 2, 18).Lower[0] < RSChannel(9, 1.5, 3, 14, 10).Mid[0])
                {
                    DrawRegion("Holding Down" , CurrentBar, 0, VMAZones(9, 2, 18).Upper, VMAZones(9, 2, 18).Lower, Color.Black, Color.Chocolate, 2);
                }

    #2
    Hello CaptainAmericaXX,
    To assist you further can you please send a toy NinjaScript code* replicating the behavior to support[AT]ninjatrader[DOT]com

    Please use the export feature of NinjaTrader to send the code.


    Please append Attn:Joydeep in the subject line of the email and give a reference of this thread in the body of the email.

    I look forward to assisting you further.

    *The "toy" just means something that is a stripped down version that isn't necessarily the whole logic. It makes things easier to rout out.
    JoydeepNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Rogers101, 05-05-2024, 11:30 AM
    16 responses
    48 views
    0 likes
    Last Post Rogers101  
    Started by ninza33, Today, 12:31 PM
    2 responses
    9 views
    0 likes
    Last Post ninza33
    by ninza33
     
    Started by Bobin, 03-12-2024, 08:51 AM
    15 responses
    481 views
    0 likes
    Last Post fiddich
    by fiddich
     
    Started by Skifree, Today, 11:21 AM
    4 responses
    13 views
    0 likes
    Last Post Skifree
    by Skifree
     
    Started by Bogdan097, Today, 03:25 PM
    0 responses
    7 views
    0 likes
    Last Post Bogdan097  
    Working...
    X