Hello friends,
I have been having hard times trying to get my EA to work. It compile correctly but it does not open trades when I backtest!
The idea is to check Moving Average cross and check stochastic, on D1, H1, M15 and M5 before initiating a trade.
Can anyone take a look at it figure out what I did not do right?
Program never enter inside the first loop <=> condition for order buy are never fullfiled
// Buy Order while( LastMediumEMA1 < LastSlowEMA1 && CurrentMediumEMA1 > CurrentSlowEMA1 && Stochastic1<60 && Stochastic1>Stochastic1_2) { Print("kjhkjhkjhkjhkjhkjhkjh"); if(LastFastMA1 < LastMediumEMA1 && CurrentFastMA1 > CurrentMediumEMA1)
By the time the medium crosses the slow, the fast has long crossed. Stop looking for crosses — look for proper order.
Drop your loops — nothing will ever change inside them. Return and retest on the next tick.
Program never enter inside the first loop <=> condition for order buy are never fullfiled
By the time the medium crosses the slow, the fast has long crossed. Stop looking for crosses — look for proper order.
Drop your loops — nothing will ever change inside them. Return and retest on the next tick.
Thank you for your time,

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hello friends,
I have been having hard times trying to get my EA to work. It compile correctly but it does not open trades when I backtest!
The idea is to check Moving Average cross and check stochastic, on D1, H1, M15 and M5 before initiating a trade.
Can anyone take a look at it figure out what I did not do right?