Hello,
my MTF (multi-timeframe) indicator works fine on opened market (when new ticks are received -> starting OnCalculate() function).
E.g.: I see D1 moving average values on 10min chart…
Problem is on the closed market where no new ticks are received. I get error 4806 (BarsCalculated function returns 0).
If I change chart period to D1 it works fine. It seems like OnCalculate() function in called indicator.ex5 is not started without new tick on different time-frame from D1?
Here is summary how I call the D1 indicator in my MTF indicator:
handle=iCustom(NULL,PERIOD_D1,"indicator.ex5",parameter);
.
.
.
calculated=BarsCalculated(handle); //returns 0 on closed market with time-frame different from D1 !!!