Announcement
Collapse
No announcement yet.
Partner 728x90
Collapse
NinjaTrader
Bar's range in text above or below the bar?
Collapse
X
-
something like that. u might have to round "barrange" up or down or convert it into a real number depending on what instrument your looking at, bc with some you might get alot of zeros like 0.000300000001 for example. but for now, that should do the trick.
double barrange=Math.Abs(High[0]-Low[0]);
if(Close[0]>=Open[0])
DrawText("range"+CurrentBar, barrange.ToString(),0 , Low[0], Color.Black);
if(Close[0]<Open[0])
DrawText("range"+CurrentBar, barrange.ToString(),0 , High[0], Color.Black);
-
Yes I figured out the first part. Had to convert to String. How do I round it?Originally posted by BigRo View Postsomething like that. u might have to round "barrange" up or down or convert it into a real number depending on what instrument your looking at, bc with some you might get alot of zeros like 0.000300000001 for example. but for now, that should do the trick.
Comment
Latest Posts
Collapse
| Topics | Statistics | Last Post | ||
|---|---|---|---|---|
|
Started by Geovanny Suaza, 02-11-2026, 06:32 PM
|
0 responses
581 views
0 likes
|
Last Post
|
||
|
Started by Geovanny Suaza, 02-11-2026, 05:51 PM
|
0 responses
338 views
1 like
|
Last Post
|
||
|
Started by Mindset, 02-09-2026, 11:44 AM
|
0 responses
103 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
554 views
1 like
|
Last Post
|
||
|
Started by RFrosty, 01-28-2026, 06:49 PM
|
0 responses
552 views
1 like
|
Last Post
by RFrosty
01-28-2026, 06:49 PM
|

Comment