[FONT=Courier New]DrawText("tag1", "[COLOR=red][B]This text was written from Indicator Window[/B][/COLOR]", 10, 1000, Color.Black);[/FONT]
Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
DrawText with Text Option in Indicator Window
Collapse
X
-
DrawText with Text Option in Indicator Window
I'm trying to include a Parameter in the Indicator Window that I can type Text into that will show up on Price Panel.
Code:Tags: None
-
Draw Text in Indicator Window
I'm trying to be able and use the new "Text" Parameter so that anything that is typed will show up on the chart...
I'm I getting warmer?
Code:[FONT=Courier New][SIZE=2][COLOR=#0000ff]#region[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] Variables[/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#008000]// Wizard generated variables[/COLOR][/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#0000ff]private[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#0000ff]string[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] text = [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800000]@"draw text here"[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2]; [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#008000]// Default setting for Text[/COLOR][/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#008000]// User defined variables (add any user defined variables below)[/COLOR][/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#0000ff]#endregion[/COLOR][/SIZE][/FONT]
Code:[FONT=Courier New][SIZE=2][COLOR=#0000ff]protected[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#0000ff]override[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#0000ff]void[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] OnBarUpdate()[/SIZE][/FONT] [SIZE=2][FONT=Courier New]{[/FONT][/SIZE] [FONT=Courier New][SIZE=2][COLOR=#008000]// Condition set 1[/COLOR][/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#0000ff]if[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] (Low[[/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]0[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2]] < High[[/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]0[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2]])[/SIZE][/FONT] [SIZE=2][FONT=Courier New]{[/FONT][/SIZE] [SIZE=2][FONT=Courier New]DrawText([/FONT][/SIZE][FONT=Courier New][SIZE=2][COLOR=#800000]"My text"[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] + CurrentBar, [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800000]"draw me some text"[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]0[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#800080]0[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2], Color.Red);[/SIZE][/FONT] [SIZE=2][FONT=Courier New]}[/FONT][/SIZE] [SIZE=2][FONT=Courier New]}[/FONT][/SIZE]Code:[FONT=Courier New][SIZE=2][COLOR=#0000ff]#region[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] Properties[/SIZE][/FONT] [SIZE=2][FONT=Courier New][Description([/FONT][/SIZE][FONT=Courier New][SIZE=2][COLOR=#800000]"this should draw text in indicator window"[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2])][/SIZE][/FONT] [SIZE=2][FONT=Courier New][Category([/FONT][/SIZE][FONT=Courier New][SIZE=2][COLOR=#800000]"Parameters"[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2])][/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#0000ff]public[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#0000ff]string[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] Text[/SIZE][/FONT] [SIZE=2][FONT=Courier New]{[/FONT][/SIZE] [FONT=Courier New][SIZE=2][COLOR=#0000ff]get[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] { [/SIZE][/FONT][FONT=Courier New][SIZE=2][COLOR=#0000ff]return[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] text; }[/SIZE][/FONT] [FONT=Courier New][SIZE=2][COLOR=#0000ff]set[/COLOR][/SIZE][/FONT][FONT=Courier New][SIZE=2] { text = value; }[/SIZE][/FONT] [SIZE=2][FONT=Courier New]}[/FONT][/SIZE]
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
576 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
334 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
101 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
553 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
551 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|


Comment