Hello everybody. This morning my new expert advisor made his first trade, but I'm thinking it was not a good deal cause it's suposed that the expert has to entry when the blue MA crosses the
yellow MA, but I don't see that in the chart... anybody knows some of
I post the logic:
//--- Check for SHORT
Print("OrderSend error ",GetLastError());
Print("Not enough money for sell ",LotsOptimized()," lots");
Print("Spread is higher than allowed");
First of all it looks like it may have crossed this morning, can't really tell from the image
Also if you're using an offset of 0 for current then it may have crossed anytime within the 15 mins triggering the trade, if it then crosses back it won't be visible on the chart as it would only the the value at the end of the candle
Please post your mql4/MT4 question on mql4/MT4 section.
It will avoid you to waste your time and other's one.
You can use Strategy Tester to run the EA on the date with visual mode to see what exactly happen.
But then again, my guess is that moving averages are lagging, and they need history bars to be filled before your EA can work out the trade, so you may not get your expected result.
Suggest you left your EA on for a few hours to a few days depending on the configured period of your moving averages, then turn on AutoTrading when the history bars are ready.
What are you talking about ? In general you are right, but MAs can be seen on his screenshot, so obviously data are available.
Yes you are right, the MAs can be seen on his screenshot, so there is chart history for the calculations of the MAs. Please pardon me.
Then it could be spread is more than his max spread or some other conditions that prevent the trade.