Schedule Script

Back to topics list To post a new topic, please log in or register
avatar
1
gmgm1504 2016.07.08 12:04
 

Hi, how I can schedule one script ? I will that the script start automatically on 14:35 PM

It is possible ? We must buy a external plugin for MT4 ?

Thanks for the Anwers, bye Guido 

avatar
12995
WHRoeder 2016.07.08 16:35 #
 
Just have it wait until the time arrives.
void OnStart(){
   #define HR1435 52500
   #define HR2400 86400
   for(;;){
      if(_StopFlag) return;
      datetime now  = TimeCurrent();
      int      time = now - now % HR2400
      if(time >= HR1435) break;
      Sleep(1000);
   }
   RefreshRates(); // Update predefines

   Your Code

Back to topics list  

To add comments, please log in or register