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!
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
NinjaTrader
Modifications to chart WPF elements and tab considerations
Collapse
X
-
Hello soulfx,
To confirm you are testing the script found here:
Hello All, Moving forward this will be maintained in the help guide reference samples and no longer maintained on the forum. Creating Chart WPF (UI) Modifications from an Indicator - https://ninjatrader.com/support/help...ui)-modifi.htm (https://ninjatrader.com/support/helpGuides/nt8/creating-chart-wpf-(ui)-modifi.htm) I've
I am not able to reproduce this behavior. Below is a link to a video I have recorded using 8.0.9.0 testing the indicator added to multiple tabs, as well as a tab with no indicator, and starting with and without connect on startup.
Free online storage and sharing with Screencast.com. 2 GB of storage and 2 GB of bandwidth per month for free. We won't compress, alter or take ownership of your content.
Using the example script, with the steps taken in the video, are you experiencing different behavior than what is shown in the video?Last edited by NinjaTrader_ChelseaB; 10-18-2017, 02:55 PM.
Leave a comment:
-
menu items appearing in the chart menu at top
Hello, In reference to the ChartCustomToolBarExample ; i based my code from some of this structure a while back.
And i have various menu items appearing on the main menu for certain tabs where a specific indicator is loaded.
This works well in general ; however when i start ninja (without a connection / or with a connect on startup) it seems all the menus items for each of the tabs (where the indicator is loaded) all appear along the top menu bar of the chart. Until i select a tab then the others clear and i now only have the menu items for the selected tab in focus.
Is there something i additionally need to do in order to Not have all the items appear when starting. Is it the case when starting ninja with multiple tabs in a chart no tab has been selected so it is not clear which items to make invisible which is handled in the tab selection handler ?
thanks
Leave a comment:
-
Hello Jesse,
Thanks for the quick response. While changing the width of the added panel can be achieved easily as per your suggestion, placing the panel on the left side of the NT chart proves to be rather difficult. Setting chartGrid to HorizontalAlignment.Left resulted in pushing both the NT chart and added panel to the left side of the canvas with a wide area of transparent canvas on the right.
Anyways, having the panel buttons on the right side of the charts does not look so bad any more.
Leave a comment:
-
Hello,
Thank you for the reply.
To change the position of where items are placed in the panel, you would need to utilize the Column and Row definitions to position your item in the layout grid.
You can see this is done in the sample in the method InsertWPFControls
a new column is added to the right of MainTabControl and all items to the right of the MainTabControl are shifted to the right to account for that item. To change this to the left would require that you change this logic to shift the MainTabControl and everything else to the right. You would also need to adjust the logic in RemoveWPFControls to account for the change.
The width is controlled in the line below this comment:
Code:// a new column is added to the right of MainTabControl chartGrid.ColumnDefinitions.Insert((tabControlStartColumn + 1), new System.Windows.Controls.ColumnDefinition() { Width = new GridLength([B]125[/B]) });
In case these concepts are difficult to visualize, these are standard WPF concepts related to Grids which there are many tutorials for online.
I look forward to being of further assistance.
Leave a comment:
-
Hello, ChelseaB
Thank you for the useful examples. For the SidePanel example, while I can change the panel background and button colors, could you please advise how to:
1. Place the side panel on the left side of the chart.
2. Change the width of the side panel.
Leave a comment:
-
Hello,
Thank you for the reply.
The same concepts can be used in a Strategy, you could reference the Indicator for a sample of the syntax required to append items to the GUI. The concepts in the indicator are able to be used wherever the ChartControl is present.
To enter strategy orders, you could use the following page as a reference to the commands: http://ninjatrader.com/support/helpG...d_approach.htm
I look forward to being of further assistance.
Leave a comment:
-
Hello,
many thanks for the sample code in first post.
About "ChartCustomSidePanelExample_NT8.zip" please could you suggest the code to add the action to a strategy?
For example the code to push Botton 1 >> enter buy market?
I have not understand how to do it!
Thanks
Leave a comment:
-
Hello,
you can find a short guide to using visual studio for debugging here: http://ninjatrader.com/support/helpG...isual%2Bstudio
The debug mode is what would flag to compile with symbols so you can utilize breakpoints when attached to NinjaTrader.
For the image, I am not certain I understand the comparison here. Are you saying that the buttons on the right side are different that the toolbar buttons? If so, yes that would be correct. The toolbar buttons are a specific style whereas the buttons on the right are just the general button style it appears. Could you provide more detail on this question if I am not seeing the correct part of the image?
I look forward to being of further assistance.
Leave a comment:
-
Really helpful
Chelsea, thanks for the support
I have couple of questions:
1. how to develop/debug these addons from the visual studio?, The cs file is placed in the indicators directory and no PDB, so not sure if there is a way to debug these addons
2. The controls inside the chart are wierd, outside ones are correctly displayed. pasting the screenshot for the inside ones. even the toolbar ones are good.
thanks,
Subhash
Leave a comment:
-
Hello Subhash,
You have not added the indicator to the chart.
No indicator will do anything if it is not added to a chart.
Add the indicator to the chart from the Indicator window.
Leave a comment:
-
-
-
Hello Subhash,
Please include a screenshot of your chart so that I may see the indicator has been applied.
Also, are there any errors in the Log tab of the Control Center?
Leave a comment:
-
Still not working
I followed the exact steps like you suggested. I checked the custom\indicators folder and the file is present and I hope that confirms that import was successful.
I launch the chart but do not see any button controls.
Leave a comment:
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by joselube001, 05-10-2024, 12:17 PM
|
5 responses
23 views
0 likes
|
Last Post
by joselube001
Today, 02:18 PM
|
||
Started by bigc0220, 09-18-2018, 09:16 AM
|
6 responses
2,579 views
0 likes
|
Last Post Today, 02:05 PM | ||
Started by lorem, 04-25-2024, 09:18 AM
|
18 responses
76 views
0 likes
|
Last Post
by lorem
Today, 02:02 PM
|
||
Started by DawnTreader, 05-08-2024, 05:58 PM
|
21 responses
81 views
0 likes
|
Last Post Today, 01:29 PM | ||
Started by doihaveto13, Today, 12:46 PM
|
2 responses
4 views
0 likes
|
Last Post
by doihaveto13
Today, 01:17 PM
|
Leave a comment: