Order Send Error 130 : Invalid Stops in BuyStop. Can someone help?

 

So I get this error in Backtesting:



And this is my code, I want to add a BuyStop at High Price from Previous Candle:

pr=iHigh(NULL,PERIOD_CURRENT,1);

ticket=OrderSend(Symbol(),OP_BUYSTOP,LotSize,pr,Slippage,0,0,NULL,MagicNumber,TimeCurrent()+3600,Blue);


I already read this forum, so I'm quite understand that I need add some points above the iHigh. I already tried many ways to no avail. Anyway, some (60%) of the buystops worked out. 

What I need to add in this code? Anyway, I'm using ECN Broker.

 
  1. Is pr above current ask by at least the minimum: MODE_STOPLEVEL * _Point or SymbolInfoInteger(SYMBOL_TRADE_STOPS_LEVEL).
              Requirements and Limitations in Making Trades - Appendixes - MQL4 Tutorial

    On some ECN type brokers the value might be zero (broker doesn't know.) Use a minimum of two (2) PIPs.

  2. Is LotSize adjusted to a multiple of LotStep and check against min and max. If that is not a power of 1/10 then NormalizeDouble is wrong. Do it right.

  3. Some brokers don't allow expiration time. Try zero.
Reason: