![MQL5 - Language of trade strategies built-in the MetaTrader 5 client terminal](https://c.mql5.com/i/registerlandings/logo-2.png)
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
As per my previous post on 'Invalid Stops' I'm in the process of learning how to code EAs. I do have some transferable skills as I used to code in Borland C back in 1990, so some aspects of this process are familiar, but coding for this environment is obvioulsy very new and I hit problems with 'invalid stops' with the first tutorial by Dillon Gech that I followed. A member here suggested I start with the tutorials listed on the forum by Trustfultrading, so that is what I have done.
However, I have problems with the results of these tutorials too. When I run the code it seems the EA is just not making trades when I would expect.
For example, the first truthfulltrading tutorial should simply open a trade at 10:00am and close at 12:00, but if you look at my screen grab that is attached, the graphical display is showing the time as 9:51 and there is a buy trade sitting in the 'middle of nowhere' at 9:51? The second attached file shows the end, again seemingly 'early'.
The vertical positioning of the blue arrow would seem to be down to the difference between the bid and ask price, but when I watch the tutorial his chart seems to show the buy being on the price line?
Many thanks for any help given.
Here is the code: