Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

AddOn Window to appear as part/sub window of the NT8 chart

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

    AddOn Window to appear as part/sub window of the NT8 chart

    Hi Everyone,

    Through NinjaScript code, I have developed an AddOn which successfully adds a button to all NT8 charts main menu on the top. I’m able to achieve that, on any open chart, when this button is clicked by user, a new window (AddOnFrameworkWindow) opens up. It opens as a separate new window.

    Instead of a new window, I need this window to appear as part/subwindow of the chart. In other words, I need this new window to appear inside the chart window/container. Like the chart Trader appears as part of the chart and not as a new window when we press chart Trader On button in NT8 charts main menu. Please guide me how can I do this in my NinjaScript code.

    Below is the code I used in this regard:

    public AddOnFrameworkWindow()
    {
    Caption = "My AddOn";
    Width = 400;
    Height = 400;
    TabControl tc = new TabControl();
    TabControlManager.SetIsMovable(tc, true);
    TabControlManager.SetCanAddTabs(tc, true);
    TabControlManager.SetCanRemoveTabs(tc, true);
    TabControlManager.SetFactory(tc, new AddOnFrameworkWindowFactory());
    Content = tc;
    tc.AddNTTabPage(new NinjaTraderAddOnProject.AddOnPage());

    Loaded += (o, e) =>
    {
    if (WorkspaceOptions == null)
    WorkspaceOptions = new WorkspaceOptions("AddOnFramework-" + Guid.NewGuid().ToString("N"), this);
    };
    }

    #2
    Hello Mubeen Haider,

    Thanks for opening the thread.

    ChartTrader is an extension to the chart window that can be disabled/enabled and hidden. I don't think it will be very easy to create your own extension by injecting your own AddOn window into the chart, since every window tab must be of the same owning window.

    Instead I may suggest that if you create an AddOn that looks at the grid within that chart, checks if your added components are there, and then adds the components to the grid and shifts as needed would be a better way forward to add your own panel of controls to all chart windows.

    My colleague, Chelsea, has some examples that demonstrate modifying the grid elements in a chart so you can add your own panel and your own controls, which should give some direction for how you can accomplish your goal.

    Modifications to chart WPF elements and tab considerations - NinjaTrader Support Forum

    Let us know if there is anything else we can do to help.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Geovanny Suaza, 02-11-2026, 06:32 PM
    0 responses
    633 views
    0 likes
    Last Post Geovanny Suaza  
    Started by Geovanny Suaza, 02-11-2026, 05:51 PM
    0 responses
    364 views
    1 like
    Last Post Geovanny Suaza  
    Started by Mindset, 02-09-2026, 11:44 AM
    0 responses
    105 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by Geovanny Suaza, 02-02-2026, 12:30 PM
    0 responses
    567 views
    1 like
    Last Post Geovanny Suaza  
    Started by RFrosty, 01-28-2026, 06:49 PM
    0 responses
    568 views
    1 like
    Last Post RFrosty
    by RFrosty
     
    Working...
    X