Download MetaTrader 5

Simple Indicator repainting (how to get it to alert at next bar closed)

To add comments, please log in or register
AlanDIRL
9
AlanDIRL  

Hey Guys,


Could someone help me out with this indicator.  I have tried to get to alert at NEXT BAR CLOSED but failed......

Thanks in advance


Alan

Files:
whroeder1
15917
whroeder1  
int limit = rates_total - prev_calculated;
for(int i = limit-1; i >= 0; i--){ ... }
return(rates_total);

After you process bar zero the first, you will never process it again, including when it becomes bar one.

Return rates_total-1. See How to do your lookbacks correctly.

AlanDIRL
9
AlanDIRL  
whroeder1:

After you process bar zero the first, you will never process it again, including when it becomes bar one.

Return rates_total-1. See How to do your lookbacks correctly.


Thank you very much
To add comments, please log in or register