This forum is in read-only mode now. You may discuss your questions on forums of MQL4.community and MQL5.community
TimeFrame in indicators?Back to topics list |
|
marynarz15
2005.07.11 04:16
How timeframe parameter works in indicators?
I wrote this indicator, but it does not shows the same for ADX in 5MIN window with timeframe 15MIN as ADX in 15MIN window int start() { int limit; int counted_bars=IndicatorCounted(); //---- check for possible errors if(counted_bars<0) return(-1); //---- last counted bar will be recounted if(counted_bars>0) counted_bars--; limit=Bars-counted_bars; //---- main loop for(int i=limit-1; i>=0; i--) { ExtMapBuffer1[i]=iADX(NULL,ADXTimeFrame,ADXPeriod,PRICE_CLOSE,MODE_MAIN,i); } //---- done return(0); } |
Download MetaTrader 5 (450 Kb, web installer) — a new terminal for financial markets
