A): Read which instrument i.e. CL 08-20 is open on each of these chart.
B): If any of these charts contain the instrument I'm looking for, then add a special indicator on that specific chart.
I want to ask whether it is technically supported by NinjaTrader 8/NinjaScript C# to obtain the above two objectives.
---------------------------------------------------------------------------------------------------------------------------------------------------------
Secondly, I tried the following code in my indicator's OnBarUpdate() method.
"Chart chartWindow = Window.GetWindow(ChartControl.Parent) as Chart;"
This line of code gives me following error: "The calling thread cannot access this object because a different thread owns it." I guess may be OnBarUpdate() is not the right place for this line of code but not sure. I need some help on correct use of a piece of code that starts with this line.
----------------------------------------------------------------------------------------------------------------------------------------------------------
I would be really grateful if someone can share similar type of code that has some resemblance with what I'm trying to achieve. Thanks very much.

Comment