Goal:
The EA places one (or two) stop order at a level (whether it is a buy or a sell or both a sell and a buy) which is defined as follows :
* if it is a sell order, the level = opening price of current M1 candle - (minus) the Distance [see below the Distance in pips on the setup panel].
* if it is a buy order, the level = opening price of current M1 candle + (plus) the Distance [see below the Distance in pips on the setup panel] .
Both a sell stop order and a buy stop order can be placed at the same time on a given instrument.
One last thing : The 'trading filter zone' ( see the relevant field just below on setup panel parameters). No buy stop order can be placed - even by the EA itself - at a higher level than the price defined on the setup panel by the user. No sell stop order can be placed - even by the EA itself - at a lower level than the price defined on the setup panel by the user.
The EA's input setup panel should present like this :
* stop order type : buy or sell or both
* Distance in pips : __
* Trading filter zone : _____
* Quantity in lots : __
* stoploss in pips: __
* trailing SL: true / false ; Trailing step: ____ ; Minimum distance to order to activate the trailing SL : ___
* take profit in pips : __
Thanks