Why not just use:
if (Hour() == 16 && Minute == 00 && !bDoneStuff)
{
... do stuff ...
bDoneStuff = true;
}
CB

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
I want something to happen every morning at 16:00 market watch. Using if(Hour() == 16 && Minute == 00 && Seconds = 00) is risky because if you don't get a tick at that second, it will never turn true so I use:
if(Hour() == 16 && Minute == 00 && Seconds = 1 ||2 || 3 ||4)
{
RUN
}
This works but I just feel there must be a better, more "logic oriented" way to go about it, any suggestions?
BB