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

new column at the execution tab at control center

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

    new column at the execution tab at control center

    I am looking to add a column on the executions tab of the control center on NT8. The column should show that chart a trade was entered into using the chart trader. I would want to know the instrument and the time frame of the chart. For example, ES 144 Tick. It's the same info that as the @DATASERIES information in the chart tabs.

    Is this possible to be achieved through add-on? Is there an existing one or should I develop one from scratch? Thank you for your time

    #2
    Hello julaya123,

    Welcome to the forums!

    This would involve using Inspect to obtain Automation ID's and then modifying the Infragistics grid. A reference to Program Files (x86)\NinjaTrader 8\bin64\InfragisticsWPF4.15.dll will need to be added before you will be able to make any modifications to this grid.

    EDIT

    The advise above could be used to get started to modify the Executions Grid, however it should be noted that we do not document any aspects of the Control Center for modification and there are several other unsupported items that will come into play to modify the grid.

    For academic purposes, I'll include some code that can help find the Executions grid and add a column, but further work will be involved to add entries appropriately for each Execution. Infragistics grid modifications would also be C# and WPF based and not specifically NinjaScript, so I would suggest using external sources to dig deeper.

    Code:
    protected override void OnWindowCreated(Window window)
    {
        ControlCenter cc = window as ControlCenter;
        if (cc == null)
            return;
    
        Gui.AccountData.ExecutionGrid execGrid = cc.FindFirst("ExecutionsGrid") as Gui.AccountData.ExecutionGrid;
        if (execGrid != null)
        {
            var layout = execGrid.NtGrid.FieldLayouts.First(f => f.Description == "ExecutionGridEntry");
    
            Infragistics.Windows.DataPresenter.Field ff = new Infragistics.Windows.DataPresenter.Field("Test");
            layout.Fields.Add(ff);
        }
    }
    Another challenge that you will run into when making such an AddOn would be finding the particular chart by the Execution. Execution and Order objects do not have information about the time frame of a chart where the order was submitted. Order and Execution objects are used throughout the platform and not only with charts.

    This particular item reaches out of the scope of support that we can offer, but I will leave this thread open for any community members who may have further input.
    Last edited by NinjaTrader_Jim; 10-19-2021, 06:33 AM.
    JimNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by wzgy0920, 04-20-2024, 06:09 PM
    2 responses
    26 views
    0 likes
    Last Post wzgy0920  
    Started by wzgy0920, 02-22-2024, 01:11 AM
    5 responses
    32 views
    0 likes
    Last Post wzgy0920  
    Started by wzgy0920, Yesterday, 09:53 PM
    2 responses
    49 views
    0 likes
    Last Post wzgy0920  
    Started by Kensonprib, 04-28-2021, 10:11 AM
    5 responses
    192 views
    0 likes
    Last Post Hasadafa  
    Started by GussJ, 03-04-2020, 03:11 PM
    11 responses
    3,234 views
    0 likes
    Last Post xiinteractive  
    Working...
    X