Script for placing a pending order when reaching a pre-set price level for MT5

MQL5 Script

Specifiche

I will first describe the process step by step:
We have a current price of the GBP / JPY pair, for example (Bid 156.97 / Ask 156.99). At this current price, I set a level 

through the settings of the script, when it is reached, a pending order is automatically placed at a set distance from this level. Maximum number of set levels - 6 levels 

regardless of above or below the current price. Validity of the set levels - unlimited term. The set level must be visible on the price chart, and it can be set and removed 

manually by the user (in case the current price has not reached it). When manually removing a set level, the associated pending order is also removed. Once the level is 

reached, a pending order such as Sell Stop, Sell Limit, Buy Stop or Buy Limit is automatically placed. The pending order is at a distance set by the script from the reached 

level and is defined simultaneously with the setting of the level (this is done through the settings of the script). Through the script it should be possible to set Take 

profit and Stop Loss of the pending order, and this should not be mandatory (entering 0 in the script settings does not set Take profit and Stop Loss). Validity of the 

pending order - unlimited term (or one month if it is impossible to set an unlimited term). IMPORTANT: When the current price reaches the price level set by the script, the 

pending order is placed at the distance set in the script, and the level automatically ceases to operate (deleted automatically). IMPORTANT: At a set level above the current 

price - the level is activated at Bid price. At a set level below the current price - the level is activated at Ask price.
For clarity, I am attaching a file.

File:

JPG
CONDITION.JPG
151.2 Kb

Con risposta

1
Sviluppatore 1
Valutazioni
(390)
Progetti
416
30%
Arbitraggio
74
19% / 70%
In ritardo
52
13%
In elaborazione
2
Sviluppatore 2
Valutazioni
(13)
Progetti
15
7%
Arbitraggio
1
100% / 0%
In ritardo
0
Gratuito
3
Sviluppatore 3
Valutazioni
(42)
Progetti
52
50%
Arbitraggio
6
83% / 0%
In ritardo
0
Gratuito
4
Sviluppatore 4
Valutazioni
(34)
Progetti
60
23%
Arbitraggio
11
73% / 9%
In ritardo
3
5%
Gratuito
5
Sviluppatore 5
Valutazioni
(16)
Progetti
29
48%
Arbitraggio
0
In ritardo
6
21%
Gratuito

Informazioni sul progetto

Budget
40+ USD
Scadenze
a 3 giorno(i)