StopLoss and TakeProfit levels cannot be too close to the market. The minimal distance
of stop levels in points can be obtained using the MarketInfo() function with MODE_STOPLEVEL parameter. In the case of erroneous or unnormalized
stop levels, the error 130 (ERR_INVALID_STOPS) will be generated.
Some brokers prevent setting stops close to price , others do not. Complain to broker.
I am actually trying to place pending orders. I have the stoplevel and it is 5pips.
Which mean the price I am trying to place should be alright.
I get this error when running my EA on the Strategy Tester.
I get this error when running my EA on the Strategy Tester.

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 getting this error which I don't understand.
I am trying to place the following order in my EA, but the strategy tester is reporting Error 130 - Invalid Stop.
Here are the information.
1. USDJPY oper: 4 lot: 0.3 openprice: 116.96 stoploss: 0 profit:0 Bid: 116.91 Ask: 116.94
2. USDJPY oper: 4 lot: 0.3 openprice: 116.99 stoploss: 0 profit:0 Bid: 116.91 Ask: 116.94
The stoplevel for USDJPY is 5 pips. And this is a BuyStop which I am trying to place above the market price.
So what went wrong here?