int start()
{
int counted_bars=IndicatorCounted();
if (iMACD(NULL,0,12,26,0,PRICE_CLOSE,MODE_MAIN,0) == 0)
{
Print("MACD Crossing Zero on ", Symbol()," at ", Close[0]," - ", TimeToStr(CurTime(),TIME_SECONDS));
}
return(0);
}
The above code will print the results on every tick of the price, how do I do it with the bar?
For example, on a 5min chart, one MACD bar is drawn once every 5 minutes, but the code above prints every time a price is generated.
Any help is appreciated.