Add smart trailing

MQL5 Uzmanlar Forex

İş tamamlandı

Tamamlanma süresi: 31 gün

Şartname

Hello,

I have the EA source code ready, and it is open-source/editable. I need you to add and improve the trailing stop logic with two clear inputs:

1. Trailing Start
2. Trailing Step

Please implement it carefully and accurately.

Trailing Start  
This is the profit distance where the EA starts activating the trailing stop.

Example:
If Trailing Start = 35 pips, the EA should not move the Stop Loss until the trade reaches +35 pips profit.

Trailing Step  
This is the step distance used to move the Stop Loss after trailing starts.

Example:
If:
Trailing Start = 35 pips  
Trailing Step = 12 pips  

Then the logic should be:

- At +35 pips profit → move SL to around +5 pips profit
- At +47 pips profit → move SL to around +17 pips profit
- At +59 pips profit → move SL to around +29 pips profit
- At +71 pips profit → move SL to around +41 pips profit
- At +83 pips profit → move SL to around +53 pips profit

The Stop Loss should always trail behind the current profit by the selected step distance.

Very important requirements:

- The EA must only move the Stop Loss forward in profit.
- The EA must never move the Stop Loss backward.
- The trailing must work correctly for both Buy and Sell trades.
- The EA must calculate pips/points correctly on XAUUSD and XAUUSDm, especially on Exness.
- The trailing must continue working correctly after partial close.
- If partial close is enabled, the EA should close 50% first, then manage the remaining position with break-even and trailing stop.
- Avoid repeated unnecessary SL modifications on every tick to prevent errors, freezing, or broker rejection.
- Please make sure the logic respects broker stop levels and minimum distance rules.
- If a manual Stop Loss already exists, the EA should respect it and only improve it when the trailing condition is reached.
- Please keep the existing EA features and only add/improve this trailing logic without breaking the current workflow.

Suggested default settings for XAUUSD:

Partial Close Trigger = 30 pips  
BreakEven Trigger = 30 pips  
BreakEven Offset = 5 pips  
Trailing Start = 35 pips  
Trailing Step = 12 pips  

Also, if you think there is a better professional improvement for gold trading, such as ATR-based trailing, spread filter, or news/time filter, please suggest it before implementation.

Please test the EA carefully on XAUUSD/XAUUSDm to make sure the trailing stop works exactly as described and without execution errors.

Yanıtlandı

1
Geliştirici 1
Derecelendirme
(2)
Projeler
2
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
2
Geliştirici 2
Derecelendirme
(267)
Projeler
335
29%
Arabuluculuk
36
28% / 64%
Süresi dolmuş
10
3%
Meşgul
3
Geliştirici 3
Derecelendirme
(213)
Projeler
286
47%
Arabuluculuk
27
59% / 37%
Süresi dolmuş
36
13%
Serbest
4
Geliştirici 4
Derecelendirme
(108)
Projeler
179
25%
Arabuluculuk
24
17% / 75%
Süresi dolmuş
16
9%
Serbest
5
Geliştirici 5
Derecelendirme
Projeler
0
0%
Arabuluculuk
1
0% / 100%
Süresi dolmuş
0
Serbest
6
Geliştirici 6
Derecelendirme
(23)
Projeler
34
53%
Arabuluculuk
1
100% / 0%
Süresi dolmuş
1
3%
Serbest
7
Geliştirici 7
Derecelendirme
(4)
Projeler
6
67%
Arabuluculuk
1
0% / 0%
Süresi dolmuş
0
Çalışıyor
8
Geliştirici 8
Derecelendirme
(463)
Projeler
806
49%
Arabuluculuk
73
19% / 52%
Süresi dolmuş
140
17%
Çalışıyor
9
Geliştirici 9
Derecelendirme
(2336)
Projeler
2939
63%
Arabuluculuk
124
44% / 26%
Süresi dolmuş
429
15%
Çalışıyor
10
Geliştirici 10
Derecelendirme
(85)
Projeler
174
44%
Arabuluculuk
3
100% / 0%
Süresi dolmuş
5
3%
Serbest
Yayınlandı: 1 kod
11
Geliştirici 11
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
12
Geliştirici 12
Derecelendirme
(22)
Projeler
29
34%
Arabuluculuk
4
50% / 25%
Süresi dolmuş
5
17%
Çalışıyor
13
Geliştirici 13
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
14
Geliştirici 14
Derecelendirme
(75)
Projeler
111
50%
Arabuluculuk
26
31% / 50%
Süresi dolmuş
9
8%
Serbest
15
Geliştirici 15
Derecelendirme
(225)
Projeler
285
41%
Arabuluculuk
15
13% / 47%
Süresi dolmuş
67
24%
Serbest
16
Geliştirici 16
Derecelendirme
(8)
Projeler
14
21%
Arabuluculuk
2
0% / 50%
Süresi dolmuş
3
21%
Yüklendi
17
Geliştirici 17
Derecelendirme
(4)
Projeler
10
50%
Arabuluculuk
1
0% / 100%
Süresi dolmuş
2
20%
Serbest
18
Geliştirici 18
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
19
Geliştirici 19
Derecelendirme
(318)
Projeler
565
35%
Arabuluculuk
81
31% / 44%
Süresi dolmuş
204
36%
Serbest
20
Geliştirici 20
Derecelendirme
(7)
Projeler
6
0%
Arabuluculuk
4
25% / 75%
Süresi dolmuş
2
33%
Serbest
21
Geliştirici 21
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
22
Geliştirici 22
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
23
Geliştirici 23
Derecelendirme
(258)
Projeler
267
30%
Arabuluculuk
0
Süresi dolmuş
3
1%
Çalışıyor
Yayınlandı: 2 kod
24
Geliştirici 24
Derecelendirme
(279)
Projeler
378
72%
Arabuluculuk
19
32% / 47%
Süresi dolmuş
16
4%
Serbest
Yayınlandı: 15 kod
25
Geliştirici 25
Derecelendirme
(28)
Projeler
34
35%
Arabuluculuk
0
Süresi dolmuş
2
6%
Serbest
26
Geliştirici 26
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
Benzer siparişler
We are seeking an experienced MQL4/MQL5 programmer to develop a high-performance, fully automated Expert Advisor (EA). The bot must execute a sophisticated multi-currency hedging strategy across correlated forex pairs. Key Responsibilities Develop Multi-Currency Logic : Build an EA capable of scanning and trading multiple currency pairs simultaneously from a single chart or setup. Implement Hedging Strategy : Code
I need an experienced MQL5 developer to create an Expert Advisor (EA) based on the trading strategy demonstrated in my video. The EA should accurately follow the entry, exit, risk management, lot size, trailing stop-loss, take-profit, and trade management rules shown. Full source code, backtesting, bug fixing, and clear input settings are required. And it should have option for Buy and Sell, then Sell only, Buy only
Търсим опитен MQL5 разработчик , който да изгради първия прототип на MetaTrader 5 Expert Advisor за дългосрочен проект за алгоритмична търговия. Изисквания към проекта Вграден Renko двигател (без офлайн Renko графики). EMA 20 и EMA 50, изчислени от тухли Renko. Логика на търговия, базирана на подробна техническа спецификация (предоставена след избор от разработчика). Експертният съветник трябва да поддържа отваряне и
I am looking for an experienced MetaTrader 5 expert. I already have 3 MT5 trading accounts. I need someone to: 1. Help me choose a reliable Windows VPS. 2. Connect to my VPS remotely (AnyDesk or TeamViewer). 3. Install 3 MetaTrader 5 terminals. 4. Configure: - 1 Master Account - 2 Slave Accounts 5. Install and configure a professional Trade Copier. 6. Copy all trades from the Master account to both Slave
Hi there developer, I need someone who can create an trading ea that place order in points using an. Vps with an stop loss in 2 point behind the order price automatically it close order in 1 point if the market reverse
I have an MT4 custom indicator (.ex4) that I use regularly, and I would like an identical MT5 version. Important: I do not have the source code (.mq4). I only have the compiled MT4 indicator. I am looking for an experienced MQL developer who can recreate the indicator's functionality and appearance for MT5 by analyzing its behavior. The MT5 version should match the MT4 version as closely as possible, including
Mac200 50+ USD
I need a Trend following Bot. Here we took entries by looking at two indicator which are 200 period ema and 12 26 9 MacD. Rules for entry exit are: Buy trade: When market is above 200 ema and MacD Line cross over the signal line and this cross over happened below the zero line of MacD indicator. We simply put Buy trade. Sell trade: When market is below 200 ema and MacD line crosses below the signal line and this
I I would like to create a trading robot based on 2 ema crossing. The robot is pretty simple, it should open buy position when fast ema cross slow ema and vise versa. Also it should use martingale after the loss position. It should has expiration period inside the code and alerts l
1. The general process is: Automated online forex marketing to find potential clients -> Answering potential clients' questions -> Converting them into actual clients -> Opening accounts, depositing funds, and copying trades. 2. Developers could implement an AI Digital Twin/Shadow Agent to answer customer questions, eliminating the need for me to answer customer inquiries. 3. I have a CTA website and I'm manually
Iconic Boy 300 - 400 USD
Am looking for a bot to trade .so that I can be able to trade and become very successful and make some profit so that I cannot sleep on a empty stomach

Proje bilgisi

Bütçe
30 - 40 USD
Son teslim tarihi
from 1 to 2 gün