Ea trailing stop for 1 or more orders

MQL4 Experts

Tâche terminée

Temps d'exécution 3 jours
Commentaires du client
good
Commentaires de l'employé
very nice and kind

Spécifications

I want to do 1 ea trailing stop for 1 or more orders.
 Rule: only count on 1 currency pair (not for every open currency pair but only for each currency pair)

 - * Average price = (price 1x size lot1 + price 2 x size lot2 +...+ price N x size lotN) / (size lot1 + size lot2 +...+ size lotN).
 - * If the total selling price 1 x size lot buy1 + selling price 2 x size lot buy2 ... > buy price 1 x size lot buy1 + buy price 2 x size lot buy2 .... --> then the direction  beneficial will be the price drop
 - * If the sum of buying prices 1 x size lot buy1 + buying price 2 x size lot buy2... > selling price 1 x size lot buy1 + selling price 2 x size lot buy2 ... --> then the direction is  The benefit will be an increase in prices

 1. SL: Initial SL for each individual order
 2. Trailing stop start: the starting point of the trailing stop, that is, when the price moves a point from the order price to the beneficial side, the trailing stop will start: a point (the yellow horizontal line can be shown on the chart).
 3. Profits lock: b points.  If the price moves a point from the order price to the beneficial side, the SL will be moved to b points, locking the profit at b points.
 4. There will be only 1 SL put together for all orders according to the Price Average when the Average runs to the Trailing stop start. All orders will use the same SL, not separate SL for each order
 5. trailing stop: c point
 6. trailing stop step: d point.  After the SL is placed at Pips lock, if the price moves further in favor of c points, then move the SL by d points to increase the locked profit.
 7. IMPORTANT: Trailing stop start a value and Pips lock b value will automatically change according to the number of open positions at that time.  When there are N open positions, Trailing stop start = a*N points and Pips lock = b*N points.
 8. IMPORTANT: trailing stop and trailing stop step are always fixed according to the setting, regardless of the number of open positions
 9. For example, when there is an order, if the price runs a point, the SL will be placed at b points, but then opens 1 more order, the total at that time is 2 orders, then there will be 2 open orders  --> On average, the price runs 2a points, the SL is placed at 2b points, after the SL has been placed at 2b, if the price runs more c points, the SL is moved by d points.
 10. If more new positions are opened, ea immediately recalculates Trailing stop start, profits lock and resets SL if Trailing stop start has been reached or deletes SL and waits if Trailing stop start is not reached.
 11. All parameters are in POINTS, 5 characters for currency pairs
 For example:
 Settings: SL 5000, Trailing stop start 1000, profits lock 500, Trailing stop 200, Trailing stop step 100
 There is an order to sell 1 EU lot at 1,00000 SL1 is 1.05000, then the price increases to 1.00500, then I place an order to sell 2 lots at 1.00500 SL2 is 1.05500.  The average price is 1.00333.  If price runs (1.00333-1000x2) to 0.98333 then SL2 and SL1 will both be SL = 0.99333 (1.00333-500x2).  If price runs (200 points) to 0.98133 , then SL will move to 0.99233 (100 points).
 However, when the price is at 0.98133 I place an order to buy 5 lots.  When averaging the price by 0.98958 (0.98133x5 > 1.00500x2 + 1,00000x1) --> the favorable direction is bullish.  The new Trailing stop start price will be (1000x3) 1.01958 --> delete the old SL (0.99233).  On the rise to 1.01958, the SL is 1.00458.

Répondu

1
Développeur 1
Évaluation
(390)
Projets
416
30%
Arbitrage
74
19% / 72%
En retard
52
13%
Travail
2
Développeur 2
Évaluation
(3)
Projets
3
0%
Arbitrage
0
En retard
1
33%
Gratuit
3
Développeur 3
Évaluation
(75)
Projets
111
50%
Arbitrage
26
31% / 50%
En retard
9
8%
Gratuit
Publié : 2 articles
4
Développeur 4
Évaluation
(72)
Projets
80
10%
Arbitrage
38
8% / 58%
En retard
6
8%
Gratuit
5
Développeur 5
Évaluation
(36)
Projets
45
2%
Arbitrage
6
33% / 17%
En retard
1
2%
Gratuit
6
Développeur 6
Évaluation
(43)
Projets
66
12%
Arbitrage
12
58% / 42%
En retard
1
2%
Gratuit
7
Développeur 7
Évaluation
(568)
Projets
641
41%
Arbitrage
25
48% / 36%
En retard
46
7%
Travail
Commandes similaires
Hi i'm looking for a trading bot that will trade on mt5/MQL5. The bot must be able to follow trend and works on any pair,chart and symbol. All distance measured with ATR. Trend from a higher time frame (default H1) with a moving average;UP/DOWN. Support and resistance found automatically from recent swing highs and low nothing drawn on the chart. Two kinds of trades, each can be switched on/off. S/R trades; price
I am looking for an EA using MT5, trading XAUUSD on PuPrime-Live6, Standard account. LIMITATIONS No martingale, no grid. Start equity 1000 EUR. Leverate 1:500 Account in USD. PuPrime-Live6 All settings (risk, time, drawdown %, cooldown, lot size) shall be adjustable on init or backtest. VERIFICATIONS The EA needs to reach the profit goals on Actual Ticks, 100ms slippage in backtests for each month 2026. profit goal
Hi All developers, I am looking for a EA which makes minimum 1:5 risk reward ratio with buy stop and sell stop orders placed based on candle open based or candle high low based or any other strategy .... If any having please share it for TEST, After proper TESTING only I will confirm the job... Please read this and respond
I’m looking for an experienced Pine Script developer to build a custom H1 price-action indicator. Requirements: Calculate levels using H1 candles only. Use New York RTH (9:30 AM–4:00 PM), excluding extended hours. Create horizontal levels when candle direction changes; dojis break the sequence. Invalidate levels only when an H1 candle body crosses them, not wicks. Confirm levels after the RTH session closes to
MT5 Trading EA — EMA/RSI Strategy with Risk Management and Trade Protection Hello, I'm looking for an experienced MQL5 developer to build a reliable Expert Advisor for MetaTrader 5 based on a simple trend-following strategy. My main priority is not adding as many features as possible. I want a clean, dependable EA that follows the specified rules consistently in both Strategy Tester and live/demo trading. 1. Trading
MT5 to DxTrade, MT5 to NinjaTrader 8, MT5 to Tradovate - Does anyone have a working copy trading system for this - like already existing system for any of this platforms, don’t want dev saying they will build one, I want copier already working - MT5 to DxTrade (Good), To Tradovate and NT8 might be complex as they are future based. That is why I asked for working system and code. Deliver demo - with a week limit if
To create a unique description that meets the freelance site's requirements, you can type the following: "I am looking for an experienced MQL5 developer to create a custom Forex Expert Advisor. The trading strategy should be based on a moving average crossover system, filtered by the Relative Strength Index indicator. The expert advisor needs to feature distinct strategy modules with adjustable settings for the
Mt5 35+ USD
//+------------------------------------------------------------------+ //| HedgingBasket_EA.mq5 | //| Copyright 2026, Trading Bot | //+------------------------------------------------------------------+ #property copyright "Trading Assistant" #property version "1.00" #include <Trade\Trade.mqh> CTrade trade; //--- Input parameters input group "=== Hedging Settings ===" input double InpLotSize = 0.01; // Lot Size for
Hi All, I am looking for a EA which makes good profit, If any having please share it for TEST, After proper TESTING only I will make the payment, no cheating no fraud, Please do not waste the time also
Custom MT5 Expert Advisor (EA) Development | MQL5 Automation Turn Your Trading Strategy into a Powerful Automated Trading System! Are you looking for a professional MT5 Expert Advisor developer to automate your trading strategy? I specialize in developing custom MetaTrader 5 (MT5) Expert Advisors and indicators using MQL5 , tailored to your trading rules, risk management preferences, and trading goals. Whether you

Informations sur le projet

Budget
30+ USD