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
i have also changed by putting this Check trailing stop function under the OnTick like this.
It does not give me errors, but even if i remove the functions still no errors.
the trailing stop is not showing any movements either.
thats my worry
when price moves 5000 points in profit i expect to see the trail stop going up 5000 but its not going up on my strategy tester
Forum on trading, automated trading systems and testing trading strategies
Can someone help me fix my EA trailing stop loss
Vladimir Karputov, 2021.01.11 16:51
How trailing works is shown in the pictures in the TrailingStop code .Thank you. i had also passed through this article trying to understand how trail works.
But Are you saying the trailing stop is working despite not seeing movement when testing the EA on strategy tester mt5 Vladimir ?
Thank you. i had also passed through this article trying to understand how trail works.
But Are you saying the trailing stop is working despite not seeing movement when testing the EA on strategy tester mt5 Vladimir ?
What does the tester have to do with it? I gave you a description and a blank - you need to change your code. You need to understand how trailing works. You need to understand that trailing takes into account several parameters: position open price, current position price, position type, current stop loss.
Just correct your code.
What does the tester have to do with it? I gave you a description and a blank - you need to change your code. You need to understand how trailing works. You need to understand that trailing takes into account several parameters: position open price, current position price, position type, current stop loss.
Just correct your code.
I finally understood what you were saying. I was not paying enough attention, my worry was about only making it to work.
Got some air, cleared my mind and revisited the Trail stop page.
I managed to make some changes and restructure the code. Now the EA seems to not read my conditions of buy and sell.
i suspect it is how i structured.
take a look
I finally understood what you were saying. I was not paying enough attention, my worry was about only making it to work.
Got some air, cleared my mind and revisited the Trail stop page.
I managed to make some changes and restructure the code. Now the EA seems to not read my conditions of buy and sell.
i suspect it is how i structured.
take a look
I combed my hair and corrected your code. I (temporarily) threw out trailing. Just study the code.
version "1.003"
I combed my hair and corrected your code. I (temporarily) threw out trailing. Just study the code.
version "1.003"
😊😊Thank you very much. That's some great piece of smart work right there.
I just went through the whole code but now running the tests, its not executing positions.
The error is invalid stops. Is it referring to sl, tp or both?
Since i will be trading indices, let me also know where to adjust when i want to switch to binary indices or currencies.
I see you pretested using USDJPY there and there was no problem.
Stop loss i had planned 10000 points
Take profit is when price reaches level 70 overbought or 30 oversold (just an example)
But we can still make Take profit 20000 points (just an example)
😊😊Thank you very much. That's some great piece of smart work right there.
I just went through the whole code but now running the tests, its not executing positions.
The error is invalid stops. Is it referring to sl, tp or both?
Since i will be trading indices, let me also know where to adjust when i want to switch to binary indices or currencies.
I see you pretested using USDJPY there and there was no problem.
Stop loss i had planned 10000 points
Take profit is when price reaches level 70 overbought or 30 oversold ( just an example)
But we can still make Take profit 20000 points (just an example)
version "1.004" - introduced normalization of Stop Loss and Take Profit. I saw that you want to work on binary options - if so, no longer contact me for help.
version "1.004" - introduced normalization of Stop Loss and Take Profit. I saw that you want to work on binary options - if so, no longer contact me for help.
***
It is the same. Sorry, I don't help such thrill-seekers. Goodbye.
It is the same. Sorry, I don't help such thrill-seekers. Goodbye.