Here is a snippet of the code, in the OnBarUpdate section: Note Bars in Progress 1 is a 144 tick dataseries
protected override void OnBarUpdate()
{
if(CurrentBar < 21) return;
if (BarsInProgress == 1)
{
if (AuHMA1.Trend[0] == 1 && AuHMA1.Trend[1] != 1 && AuLinReg1.Trend[0] == 1 )
{
UpArrow[0] =1;
if (BarsInProgress == 0) entryBar = CurrentBar;
}
else UpArrow[0] =0;
if (AuHMA1.Trend[0] == -1 && AuHMA1.Trend[1] != -1 && AuLinReg1.Trend[0] ==-1 && CurrentBar != entryBar)
{
DownArrow[0] = 1;
//Draw.ArrowDown(this, "ARROWDOWN" + CurrentBar, false, 0, High[0]+TickSize*1, long_Exit_Color);
if (BarsInProgress == 0) entryBar = CurrentBar;
}
else DownArrow[0] =0;
}
/// Bars in progress is 0 for this code
if (UpArrow[0] == 1 && UpArrow[1] == 0 && CurrentBar != entryBar) Draw.ArrowUp(this, "ARROWUP" + CurrentBar, false, 0, Low[0]-TickSize*1, long_Entry_Color);
if (DownArrow[0] == 1 && DownArrow[1] == 0 && CurrentBar != entryBar ) Draw.ArrowDown(this, "ARROWDOWN" + CurrentBar, false, 0, High[0]+TickSize*1, long_Exit_Color);
}
Trying to figure out how to eliminate the multiple arrows to just one?

Comment