I figured out this doesn't happen on MetaQuotes Demo account, only on ActivTrades Demo Account!

Documentation on MQL5: Standard Constants, Enumerations and Structures / Environment State / Account Properties
- www.mql5.com
Standard Constants, Enumerations and Structures / Environment State / Account Properties - Documentation on MQL5
Maybe ActiveTrades stoplevel is higher than MetaQuotes stoplevel.
Even if im using sl and tp about 1ctfrom the price this is happening
martinm:
Hi guys,
I've got an expert advisor creating orders with:
Look at the code of this guy: https://www.mql5.com/en/articles/442
He modifies his orders in order to set the trailing stops (request.action=TRADE_ACTION_SLTP;)... the system works well.
I tried to modify the code for my own EAs, but Im having the same errors you are experiencing... :(

Money-Making Algorithms Employing Trailing Stop
- 2012.07.16
- Гребенев Вячеслав
- www.mql5.com
This article's objective is to study profitability of algorithms with different entries into trades and exits using trailing stop. Entry types to be used are random entry and reverse entry. Stop orders to be used are trailing stop and trailing take. The article demonstrates money-making algorithms with a profitability of about 30% per annum.

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 guys,
I've got an expert advisor creating orders with: