Author: @冻龄男孩
0 Views
0 Downloads
0 Favorites
sjqj
ÿþ//+------------------------------------------------------------------+

//|                                                         sjqj.mq5 |

//|                                                            @»Q„Ÿ7ui[ |

//|                                             https://www.mql5.com |

//+------------------------------------------------------------------+

#property copyright "@»Q„Ÿ7ui["

#property link      "https://www.mql5.com"

#property version   "1.00"

input string EA_ËYöeô•="00:01:00",EAÓ~_göeô•="22:50:00";

//+------------------------------------------------------------------+

//| Expert initialization function                                   |

//+------------------------------------------------------------------+

int OnInit()

  {

//---

   

//---

   return(INIT_SUCCEEDED);

  }

//+------------------------------------------------------------------+

//| Expert deinitialization function                                 |

//+------------------------------------------------------------------+

void OnDeinit(const int reason)

  {

//---

   

  }

//+------------------------------------------------------------------+

//| Expert tick function                                             |

//+------------------------------------------------------------------+

void OnTick()

  {

//---

   bool $R­e=öeô•$R­e(EA_ËYöeô•,EAÓ~_göeô•,TimeCurrent());

  }

//+------------------------------------------------------------------+

bool  öeô•$R­e(string _ËYöeô•,string Ó~_göeô•,ulong ÂS€öeô•,int ùX
g05u=0,int GMTOPûy=0)

  {

   if(ùX
g05u==1)

      ÂS€öeô•=TimeCurrent();

   if(ùX
g05u==2)

      ÂS€öeô•=TimeLocal();

   ÂS€öeô•=ÂS€öeô•+GMTOPûy*3600;

   ulong  _ËYÒype=((ulong)StringToTime(_ËYöeô•))%86400;

   ulong  Ó~_gÒype=((ulong)StringToTime(Ó~_göeô•))%86400;

   ÂS€öeô•=ÂS€öeô•%86400;

   if(Ó~_gÒype<_ËYÒype)

     {

      if(ÂS€öeô•>=_ËYÒype || ÂS€öeô•<Ó~_gÒype)

         return(true);

     }

   else

     {

      if(ÂS€öeô•>=_ËYÒype && ÂS€öeô•<Ó~_gÒype)

         return(true);

     }

   return(false);

  }

////-------------------------(u—_}YÙ~*N”Nf-------------------------

////-------------------------(u—_}YÙ~*N”Nf-------------------------

////-------------------------(u—_}YÙ~*N”Nf-------------------------



Comments