guignath:
Hi,
I am just looking for a way to get the day of the week from my LocalTime in a program.
Is there a way/function for that please ?
Tx in advance;
MT4 or MT5?
For MT4 it is simple :
TimeDayOfWeek(TimeLocal());
For MT5 a just bit more complicated - you can do something like this :
MqlDateTime _timeLocal; TimeToStruct(TimeLocal(),_timeLocal); int _timeDayOfWeek = _timeLocal.day_of_week;or use the _timeLocal.day_of_week directly (without creating a new variable)
Mladen Rakic:
Tx! That was for MT5 ;)
MT4 or MT5?
For MT4 it is simple :
For MT5 a just bit more complicated - you can do something like this :

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
Hi,
I am just looking for a way to get the day of the week from my LocalTime in a program.
Is there a way/function for that please ?
Tx in advance;