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 SalmaTrader, 07-07-2026, 10:26 PM
|
0 responses
35 views
0 likes
|
Last Post
by SalmaTrader
07-07-2026, 10:26 PM
|
||
|
Started by CarlTrading, 07-05-2026, 01:16 PM
|
0 responses
20 views
0 likes
|
Last Post
by CarlTrading
07-05-2026, 01:16 PM
|
||
|
Started by CaptainJack, 06-17-2026, 10:32 AM
|
0 responses
12 views
0 likes
|
Last Post
by CaptainJack
06-17-2026, 10:32 AM
|
||
|
Started by kinfxhk, 06-17-2026, 04:15 AM
|
0 responses
18 views
0 likes
|
Last Post
by kinfxhk
06-17-2026, 04:15 AM
|
||
|
Started by kinfxhk, 06-17-2026, 04:06 AM
|
0 responses
20 views
0 likes
|
Last Post
by kinfxhk
06-17-2026, 04:06 AM
|

Comment