Ingvar Engelbrecht:
Seems an MT4 bug, not ?This code:
data.ThisTimeStamp[i] = (datetime) SeriesInfoInteger(data.symbol[i],data.ThisTF[i],SERIES_LASTBAR_DATE);
It will only return the correct value if the corresponding chart is open in the terminal. Otherwise it returns zero.
The format
Makes developing multicurrency EA:s cumbersome.
The MQL4 Reference available from MetaEditor does not specify this requirement
The other format does not return false and the datetime is also zero
if(SeriesInfoInteger(data.symbol[i],data.ThisTF[i],SERIES_LASTBAR_DATE,lw)== false)
Why not use ?
CopyTime(data.symbol[i],data.ThisTF[i],0,1,lastbar);
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
This code:
data.ThisTimeStamp[i] = (datetime) SeriesInfoInteger(data.symbol[i],data.ThisTF[i],SERIES_LASTBAR_DATE);
It will only return the correct value if the corresponding chart is open in the terminal. Otherwise it returns zero.
The format
Makes developing multicurrency EA:s cumbersome.
The MQL4 Reference available from MetaEditor does not specify this requirement
The other format does not return false and the datetime is also zero
if(SeriesInfoInteger(data.symbol[i],data.ThisTF[i],SERIES_LASTBAR_DATE,lw)== false)