Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Adding DASH options to an exisitng indicator - Repeater
Collapse
X
-
Hi rdtdale,
I noticed that you need to add a variable for "Draw.RegionHighlightX". Next, you can set the style for it.
Below is the example:
Code:if (toolType[i] == ToolSelector.TimeRegion) { DateTime test = Time[0].Date + startStop[i, 2]; RegionHighlightX rH = Draw.RegionHighlightX(this, label[i], Time[CurrentBar - beginBar[i]], test, showOutline[i] ? brushColor[i] : Brushes.Transparent, brushColor[i], opacity[i]); rH.OutlineStroke = new Stroke(brushColor[i], DashStyleHelper.DashDot, 1); }
Regards,
JoyLast edited by ninZa; 08-05-2024, 07:08 AM.
-
Comment
-
Hi rdtdale,
If you want to add an option so the user can choose the style for the line, please follow the steps below:
1. At the "Properties" region, please add a property named "LineStyle", this property will refer to a lineStyle variable, and their type is "Stroke".
2. At the "variables" region, add a variable named "lineStyle" (type "Stroke").
3. Now, you can set the style for your drawing object. Just set the outline style of the object equal to the "LineStyle" property.
4. The user can change the line style in the settings window by changing the value of the "Line Style" parameter in the "Graphics" section.
I Attached a picture and a modified file below. Please download it for more details.
Regards,
Danny
Comment
-
Hi ninZa...thanks for this....this language seems quite complex to learn. I added what you suggested at the ARROWS and it work partly. The region would show the DASH but only on one of the lines. I use this to create 90 min windows for AMD, and also 30 min windows for macro time to look for a setup based on a Breaker Block. So far this code is the closet for NT...contacting the original Author did not work. Thanks again.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
624 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
359 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
105 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
562 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
567 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment