Your topic has been moved to the section: Expert Advisors and Automated Trading — https://www.mql5.com/en/forum/172166/page6#comment_49114893
Raphael A: I don't understand why the condition CurrentTime == "00:00" is true during 15 minutes and not only 1 minute.
Maybe because the broker has markets closed during the first 15 mins of the 0:00 hour, so please check the Market schedule for the broker and symbol.
The CurrentTime function returns the trade server time, and if there is no activity and no ticks coming in, then the server time is not updated.
Fernando Carreiro #:
Maybe because the broker has markets closed during the first 15 mins of the 0:00 hour, so please check the Market schedule for the broker and symbol.
The CurrentTime function returns the trade server time, and if there is no activity and no ticks coming in, then the server time is not updated.
Thank you, TimeLocal does the job
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
Hi all,
I am trying to collect the day open equity so I can control my daily drawdown and close all trade if it gets reached. However I don't understand why it is not working. Here is the following code I am testing:
The Print statement gets executed every 15 seconds from 00:00:00 until 00:14:45. I don't understand why the condition CurrentTime == "00:00" is true during 15 minutes and not only 1 minute.
Please help. And if you a more efficient to collect day open equity I am interested also.
Thanks