So I'm trying to reference a trend line object in a strategy, that trend line is drawn from another indicator. I'm currently aware of the foreach(IDrawObject draw in DrawObjects) trick, but its not seeing any of the lines drawn by the indicator. It can see manually drawn ones, and I'm positive the lines being drawn are objects not plots. Any ideas?
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Indicator trend lines
Collapse
X
-
Indicator trend lines
Hi,
So I'm trying to reference a trend line object in a strategy, that trend line is drawn from another indicator. I'm currently aware of the foreach(IDrawObject draw in DrawObjects) trick, but its not seeing any of the lines drawn by the indicator. It can see manually drawn ones, and I'm positive the lines being drawn are objects not plots. Any ideas? -
Hello joe jack,
That depends on how the indicator is drawing the line. It can be either the Line Class: http://www.ninjatrader.com/support/h...line_class.htm
Otherwise, it can be drawn manually: http://www.ninjatrader.com/support/h...l?drawline.htm
For the Line Class drawn objects you may view the following forum post for a reference.
http://www.ninjatrader.com/support/f...ad.php?t=49055JCNinjaTrader Customer Service
-
Hello joe jack,
You may use the following example to try to get the value of a Line from another indicator:
Otherwise, you may contact the vendor to see how it was programmed.Code:// ADXR "Lower" Line Print("Test output Line value: "+ ADXR(10, 14).Lines[0].Value);JCNinjaTrader Customer Service
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
599 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
344 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
103 views
0 likes
|
Last Post
by Mindset
02-09-2026, 11:44 AM
|
||
|
Started by Geovanny Suaza, 02-02-2026, 12:30 PM
|
0 responses
558 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
557 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment