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 Hwop38, 05-04-2026, 07:02 PM
|
0 responses
164 views
0 likes
|
Last Post
by Hwop38
05-04-2026, 07:02 PM
|
||
|
Started by CaptainJack, 04-24-2026, 11:07 PM
|
0 responses
319 views
0 likes
|
Last Post
by CaptainJack
04-24-2026, 11:07 PM
|
||
|
Started by Mindset, 04-21-2026, 06:46 AM
|
0 responses
246 views
0 likes
|
Last Post
by Mindset
04-21-2026, 06:46 AM
|
||
|
Started by M4ndoo, 04-20-2026, 05:21 PM
|
0 responses
350 views
0 likes
|
Last Post
by M4ndoo
04-20-2026, 05:21 PM
|
||
|
Started by M4ndoo, 04-19-2026, 05:54 PM
|
0 responses
179 views
0 likes
|
Last Post
by M4ndoo
04-19-2026, 05:54 PM
|

Comment