If this is not possible in an Indicator, then please describe how to do it in a Strategy. I just want someone to set it up so that the chart runs some code when the instrument has changed.
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
Running C# code when the instrument has changed
Collapse
X
-
Running C# code when the instrument has changed
How could I run some C# code upon the changing of an instrument on a chart?
If this is not possible in an Indicator, then please describe how to do it in a Strategy. I just want someone to set it up so that the chart runs some code when the instrument has changed.Tags: None
-
Hello NinjaCustomer,
Thanks for your post.
If you have an instrument on the chart and indicators, when you switch instruments on the chart, all of your indicators would run again as if being applied for the first time.
Can you clarify further what you are trying to accomplish when switching instruments?Paul H.NinjaTrader Customer Service
-
-
-
Hello NinjaCustomer,
Thanks for your reply.
You would need to add the file location in the "References".
in the Ninjascript editor, open any indicator (or strategy) for editing. Right mouse click on the source code and select "References...". In the References window, left click the "add" text which will open a file explorer window, navigate to the file location, select the file "user32.dll" and click the "Open" button. This will add the reference to the reference window, click the "OK" button.Paul H.NinjaTrader Customer Service
Comment
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by agclub, 04-21-2024, 08:57 PM
|
5 responses
32 views
0 likes
|
Last Post
by agclub
Today, 09:47 PM
|
||
Started by ESHunter, Today, 08:06 PM
|
2 responses
18 views
0 likes
|
Last Post
by ESHunter
Today, 09:27 PM
|
||
Started by ETFVoyageur, 05-07-2024, 07:05 PM
|
19 responses
150 views
0 likes
|
Last Post
by ETFVoyageur
Today, 09:14 PM
|
||
Started by ETFVoyageur, Yesterday, 10:13 PM
|
3 responses
26 views
0 likes
|
Last Post
by ETFVoyageur
Today, 09:08 PM
|
||
Started by ETFVoyageur, Yesterday, 12:52 AM
|
3 responses
33 views
0 likes
|
Last Post
by ETFVoyageur
Today, 09:05 PM
|
Comment