EA action at 04:59am

 

Hi,

Is there a reason why this code doesnt work?

if (TimeCurrent()==StrToTime("04:59"))

I want my EA to perform an action at 04:59 am... but this code doesn't seem to work.

Thanks a lot.

 
  1. Your code cannot be compiled: ..("04:59))
  2. What if no tick arrives at exactly this second 04:59:00 that start OnTick or OnCalculate()
  3. What if within this second two or more ticks arrives?
Reason: