![]() |
|
|||||||
| Indicator Development Support for the development of custom indicators using NinjaScript. |
![]() |
|
|
Thread Tools | Display Modes |
|
|
#1 |
|
Member
Join Date: Aug 2007
Posts: 38
Thanks: 0
Thanked 0 times in 0 posts
|
Hello
i wanted to make a BarColor change when the Momentum goes down, it works but only if i have one condition, the second i add another conditions for example a Low [0] <= Low [1] the bar colors dont get changed: protected override void OnBarUpdate() { Value.Set(CurrentBar == 0 ? 0 : Input[0] - Input[Math.Min(CurrentBar, Period)]); if (Value[0] >= 0 && Low [0] <= Low [1] && Value[1] >= Value[0] ) { BarColor = Color.Red; } What i am making wrong here, or is it only possible in strategies to have a && command in the if section? |
|
|
|
|
|
#2 |
|
Administrator
Join Date: Mar 2005
Location: Bamberg, Germany
Posts: 9,994
Thanks: 0
Thanked 6 times in 6 posts
|
Please see here: http://www.ninjatrader-support.com/v...ead.php?t=3170
Dierk
NinjaTrader Customer Service |
|
|
|
![]() |
| Thread Tools | |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| TRO Indicators | NinjaTrader_Josh | NinjaScript File Sharing Discussion | 148 | 09-07-2012 11:24 AM |
| Placing more than 1 stop orders, not allowed? | pipal | SuperDOM and other Order Entry Windows | 4 | 05-16-2008 12:14 PM |
| Charting indicators using other indicators as the input | Elliott Wave | Charting | 3 | 04-04-2008 03:54 PM |
| Maximum frequency of order modification allowed? | MarkSanDiego | Automated Trading | 1 | 02-27-2008 02:15 PM |
| Indicators | michaeldavidmiller@comcas | ATM Strategies (Discretionary Trading) | 1 | 01-13-2008 01:52 AM |