Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Rectangle with 2 different colors
Collapse
X
-
Rectangle with 2 different colors
Do you know if there is an indicator or a way to draw a rectangle with 2 different background colors? Thank you very much.Tags: None
-
Hello punkiy2111,
Thanks for your post.
If you are looking for an existing indicator that accomplishes this then you could browse the Ecosystem User App Share for a possible solution.
Ecosystem User App Share:
Otherwise, you could use SharpDX in OnRender() to draw a rectangle on the chart with a gradient Brush color such as a red to blue gradient. Note that you could convert a LinearGradientBrush to a SharpDX brush using ToDxBrush().
See the attached example script demonstrating how this could be done.
And, see the help guide documentation below for more information.
OnRender():https://ninjatrader.com/support/help...8/onrender.htm
Using SharpDX to custom render objects on a chart: https://ninjatrader.com/support/help..._rendering.htm
Let me know if I may further assist.Attached Files<span class="name">Brandon H.</span><span class="title">NinjaTrader Customer Service</span><iframe name="sig" id="sigFrame" src="/support/forum/core/clientscript/Signature/signature.php" frameborder="0" border="0" cellspacing="0" style="border-style: none;width: 100%; height: 120px;"></iframe>
- Likes 1
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by CaptainJack, 05-29-2026, 05:09 AM
|
0 responses
232 views
0 likes
|
Last Post
by CaptainJack
05-29-2026, 05:09 AM
|
||
|
Started by CaptainJack, 05-29-2026, 12:02 AM
|
0 responses
150 views
0 likes
|
Last Post
by CaptainJack
05-29-2026, 12:02 AM
|
||
|
Started by charlesugo_1, 05-26-2026, 05:03 PM
|
0 responses
161 views
1 like
|
Last Post
by charlesugo_1
05-26-2026, 05:03 PM
|
||
|
Started by DannyP96, 05-18-2026, 02:38 PM
|
1 response
243 views
0 likes
|
Last Post
|
||
|
Started by CarlTrading, 05-11-2026, 05:56 AM
|
0 responses
198 views
0 likes
|
Last Post
by CarlTrading
05-11-2026, 05:56 AM
|

Comment