hello, my EA cannot open position mean while it must open buy position when AC indicator have a negative number .
whats its wrong, please.
Just creating an object of some class is not enough. You need to initialize the indicator, you need to update the indicator data ...
Just creating an object of some class is not enough. You need to initialize the indicator, you need to update the indicator data ...
hello, i do what you said such as initialize the indicator and update the indicator data . what else you want me to do?
also , in this level i just want open position not extra things like: stop lost , take profit and close position.(please check new attached file)
hello, i do what you said such as initialize the indicator and update the indicator data . what else you want me to do?
also , in this level i just want open position not extra things like: stop lost , take profit and close position.(please check new attached file)
Forum on trading, automated trading systems and testing trading strategies
Help with MA cross and price crossing another MA
Vladimir Karputov, 2021.12.28 04:39
You have a global error - you create several indicator handles at each tick.
Remember: according to the MQL5 style, the indicator handle must be created ONCE and must be done in OnInit.
Example:
Creating an iMA indicator handle, getting indicator values
Vladimir you are right but please pay attention i fix last problems and now in my strategy tester, EA open position correctly according to indicator signal but it cannot set take-profit or stop-loss therefore i think handle of indicator is not important now and we must fix this journals error (error when it want set take-profit and stop-loss):
cannot modify position cause position doesn't exist (meanwhile position is open)
Vladimir you are right but please pay attention i fix last problems and now in my strategy tester , EA open position correctly according to indicator signal but it cannot set take-profit or stop-loss therefore i think handle of indicator is not important now and we must fix this journals error (error when it want set take-profit and stop-loss):
cannot modify position cause position doesn't exist (meanwhile position is open)
Until you correct your global mistake, you cannot move on. You shouldn't make such gross mistakes! Is it really so hard to read the help and correct your BIGGEST MISTAKE ???
Correct your BIGGEST BUG!
- 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, my EA cannot open position mean while it must open buy position when AC indicator have a negative number .
whats its wrong, please.