Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Actual Bar Properties

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

    Actual Bar Properties

    Hello,

    I am looking for solutions how to change the last (actual) bar referring to conditions in an indicator.

    In the forum I found how to change the color and the outline. But I want to ask if I can

    a.) change the size of the last bar or

    b.) when using ohlc to have the last bar a candlestick (because body can be colored)


    Thank you!
    Tony
    Last edited by tonynt; 08-14-2015, 03:13 AM. Reason: Found one solution for c.)

    #2
    Hello Tony,

    Thank you for writing in. There are no supported built-in NinjaScript methods to do what you want to do unfortunately. You will ultimately want to override the Plot method and then replace the last bar with a custom candlestick bar that you create the logic for.

    Here is the syntax to override the Plot method to get started:
    public override void Plot(Graphics g, Rectangle r, double min, double max){}

    To know how to work with the code inside the Plot() method, I recommend opening up a bar type and looking at its code. You can find your bar types in (My) Documents\NinjaTrader 7\bin\Custom\Type\BarTypes.cs

    As this is unsupported, I do not have any more information for you but we will leave this post open in case another forum member has some insight for you.

    Please let me know if I may be of further assistance.
    Michael M.NinjaTrader Quality Assurance

    Comment


      #3
      Hello,

      when is a post open and when closed?

      Working here for years now and dont know about, sorry.

      Best
      Tony

      Comment


        #4
        Hello Tony,

        I apologize for the confusion. This just means that because what you are trying to do is unsupported, other members of the forum will be able to provide further assistance from this point.

        Please let me know if you have any specific questions concerning NinjaScript.
        Michael M.NinjaTrader Quality Assurance

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by CarlTrading, Yesterday, 11:51 AM
        0 responses
        12 views
        0 likes
        Last Post CarlTrading  
        Started by CarlTrading, Yesterday, 11:48 AM
        0 responses
        19 views
        0 likes
        Last Post CarlTrading  
        Started by CaptainJack, 03-25-2026, 09:53 PM
        0 responses
        16 views
        0 likes
        Last Post CaptainJack  
        Started by CaptainJack, 03-25-2026, 09:51 PM
        0 responses
        13 views
        0 likes
        Last Post CaptainJack  
        Started by Mindset, 03-23-2026, 11:13 AM
        0 responses
        18 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Working...
        X