Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Indicator Code Execution on Multiple Chart Tabs of same Chart Window

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

    Indicator Code Execution on Multiple Chart Tabs of same Chart Window

    Hi Ninja Experts,

    I need some guidance about an interesting scenario which I have come across while building an indicator. I have converted the problem into a simple experiment, I explain below:

    I have got a chart window in which several chart tabs are open and every chart tab has a different instrument loaded on it. I have created an indicator which is applied on each chart tab. The indicator is designed to print the name of instrument plotted on that specific chart tab on closure of each bar (OnBarUpdate).
    I have observed that the OnBarUpdate() method of only that indicator instance prints the name of instrument whose tab is currently selected by me. The non-selected tab's indicator and its OnBarUpdate() method sit silent until I change the tab and select another one. Now the indicator of this newly selected tab starts printing and the rest of tabs indicators sit silent.

    A very important observation here is that the newly selected tab prints all the previously pending messages now upon selection (For example, if I land on a new tab after 10 min where bar time frame is 1 min, the pending 10 prints come together upon selection of the tab). So, I feel like OnBarUpdate methods holds all its outputs (print messages) until that tab is selected by the user.

    It is very crucial for me that all tabs' indicators OnBarUpdate methods keep working (or lets say printing) to achieve the required functionality. I request Ninja experts to help me in this regard with some relevant example codes, literature etc.

    Best Regards,
    Last edited by Mubeen Haider; 02-04-2022, 11:48 AM.

    #2
    Hi Mubeen, thanks for posting.

    Generated indicators have IsSuspendedWhileInactive = true; by default. Set this to false in State.SetDefaults and it should resolve.

    Kind regards,
    -ChrisL

    Comment


      #3
      Hi Chris, resolved, no words to appreciate your immediate and to the point help. In addition to being very thankful to you, I'd say almost every time I needed a help, I got good support from NinjaTrader Customer Service. You people are helping me to grow. Thanks.

      Comment


        #4
        Thanks Mubeen, Im happy to help.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by Geovanny Suaza, 02-11-2026, 06:32 PM
        0 responses
        580 views
        0 likes
        Last Post Geovanny Suaza  
        Started by Geovanny Suaza, 02-11-2026, 05:51 PM
        0 responses
        336 views
        1 like
        Last Post Geovanny Suaza  
        Started by Mindset, 02-09-2026, 11:44 AM
        0 responses
        103 views
        0 likes
        Last Post Mindset
        by Mindset
         
        Started by Geovanny Suaza, 02-02-2026, 12:30 PM
        0 responses
        554 views
        1 like
        Last Post Geovanny Suaza  
        Started by RFrosty, 01-28-2026, 06:49 PM
        0 responses
        552 views
        1 like
        Last Post RFrosty
        by RFrosty
         
        Working...
        X