HI, FX has always been a bit of a headache for me regarding time, time zones, daylight time shifts and market open/closes !
I have built a strategy that I would like to trade only during the hours of 07:00 GMT and 22:00 GMT
or even have times I can adjust.
how would I go about doing this ?
and how would I adjust for DST etc…
Timestamps in MetaTrader always represent server-time
Don’t forget that London for example opens at 7 o’clock which is 6 GMT in summer when DST is ON and 7 GMT when DST is OFF
I have my conditions set to always check the time if it’s 7 o’clock. I don’t bother with GMT and DST settings since timestamps always represent London time and open is always at 7
No i was talking more about the times in the EA’s, where do the reference to? say i want an EA to start trading at 7:00GMT is it getting the time from the broker (Oanda GMT -5) or is it getting the time from my pc ?
how would i know its trading the london open each day even if daylight savings is changing ??
If you want your EA to trade strictly at 7 GMT you need to implement rules to solve zone and DST shift. MetaTrader shows server time i.e. OANDA broker. In EA Wizard you can create a variable DST true/false and make it as a expert advisor input to be able to set shift ‘on the fly’ according to setting for current day/period
You must be logged in to reply to this topic.