MQL4 Reference
Date & Time functions
Hour
Returns the hour (0,1,2,..23) of the last known server time by the moment of the program start (this value will not change within the time of the program execution).
Note: At the testing, the last known server time is modelled.
Sample:
bool is_siesta=false;
if(Hour()>=12 || Hour()<17)
is_siesta=true;
|
|
|