Martingle

Specifiche


File Name: ReverseOrderEA_Description.txt
Purpose: Describes the functionality of the MQL5 Expert Advisor ReverseOrderEA.mq5

---

EA Name:
ReverseOrderEA.mq5
Automated MQL5 Expert Advisor that places reverse pending orders based on existing open trades.

---

Functionality Overview:

This EA monitors all open positions on the current chart symbol and automatically places a reverse pending order (Buy Stop or Sell Stop) based on the trade’s stop loss (SL). The logic ensures:

- Only one reverse pending order per open position.
- Reverse orders are deleted and re-placed if the SL, lot size, or entry changes.
- Reverse orders are canceled if the original position is closed (manually or otherwise).
- Reverse lot size is calculated using a multiplier (default 1.0).

---

Reverse Order Logic:

- BUY position:
  - Reverse = Sell Stop at the SL.
  - SL = original entry.
  - TP = SL − (2 × risk).

- SELL position:
  - Reverse = Buy Stop at the SL.
  - SL = original entry.
  - TP = SL + (2 × risk).

---

Key Components:

✅ CheckAndPlaceReversePendingOrder()
- Loops through open positions.
- Calculates reverse price, SL, TP.
- Ensures only one reverse order exists per position.
- Calls DeleteReverseIfChanged() if parameters differ.
- Places new pending orders with appropriate comment format.

🗑️ DeleteReverseIfChanged()
- Deletes existing reverse pending orders if:
  - SL, lot size, or entry price has changed.

🚫 CancelUnusedReverseOrders()
- Deletes reverse orders if the original position is closed or no longer exists.

---

Comment Format:

All reverse orders include a comment:
Reverse_<ticketNumber>_<SL>
This enables matching each pending order to its original trade and verifying its parameters.

---

Inputs:

- lotMultiplier — Multiplier for reverse lot size (e.g., 2 = double lot size).
- magicNumber — Unique magic number to track reverse orders only.
- reversePrefix — Text prefix in order comment (default "Reverse").

---

OnTick Logic:

1. CheckAndPlaceReversePendingOrder()
2. CancelUnusedReverseOrders()

Both are called every tick to keep reverse order logic accurate and synchronized.

---

Notes:

- Works only with positions on the current chart symbol.
- Requires SL on original position to function.

- Does not initiate trades itself — only creates reversals for existing ones.


want to add lot size and tp as step 

// Recovery logic

double lotSteps[] =       {0.01, 0.02, 0.02, 0.04, 0.04, 0.08, 0.08, 0.04, 0.04, 0.08, 0.08};

double tpMultipliers[] =  {2.0,  2.0,  2.5,  2.5,  3.0,  3.0,  4.0,  4.0,  4.0,  4.0,  4.0};


Con risposta

1
Sviluppatore 1
Valutazioni
(210)
Progetti
273
21%
Arbitraggio
24
54% / 17%
In ritardo
0
In elaborazione
2
Sviluppatore 2
Valutazioni
(70)
Progetti
91
25%
Arbitraggio
26
19% / 54%
In ritardo
25
27%
Gratuito
3
Sviluppatore 3
Valutazioni
(31)
Progetti
38
53%
Arbitraggio
2
50% / 50%
In ritardo
3
8%
Gratuito
4
Sviluppatore 4
Valutazioni
(19)
Progetti
31
32%
Arbitraggio
8
50% / 25%
In ritardo
3
10%
In elaborazione
5
Sviluppatore 5
Valutazioni
(12)
Progetti
12
17%
Arbitraggio
2
0% / 50%
In ritardo
1
8%
Gratuito
6
Sviluppatore 6
Valutazioni
(1)
Progetti
2
50%
Arbitraggio
3
0% / 33%
In ritardo
0
Gratuito
7
Sviluppatore 7
Valutazioni
(10)
Progetti
14
43%
Arbitraggio
0
In ritardo
3
21%
Gratuito
8
Sviluppatore 8
Valutazioni
(271)
Progetti
553
50%
Arbitraggio
57
40% / 37%
In ritardo
227
41%
In elaborazione
9
Sviluppatore 9
Valutazioni
(2)
Progetti
2
0%
Arbitraggio
0
In ritardo
0
Gratuito
10
Sviluppatore 10
Valutazioni
(4)
Progetti
5
40%
Arbitraggio
1
0% / 0%
In ritardo
0
Gratuito
11
Sviluppatore 11
Valutazioni
Progetti
0
0%
Arbitraggio
0
In ritardo
0
Gratuito
12
Sviluppatore 12
Valutazioni
(574)
Progetti
945
47%
Arbitraggio
309
58% / 27%
In ritardo
125
13%
Gratuito
Ordini simili
i share my strategy i need a bot trending bot fo mt5 . i attached the photo with this it help to make bot. it basicly 1 hours time frame base. i try but failed to make it
Title: Simple background trading bot for my Oanda account (v20 REST API) Overview Hi, I need a simple, lightweight event based standalone trading bot that connects directly to my Oanda account using broker’s standard REST API (V20 account) via VPS The bot just needs to look at group of 5 currency pairs (manually selectable and adjustable) in different 4 baskets, do some basic percentage math every period, and place
Hi developer I want to convert my mt4 EA to mt5 EA . I have a mt4 ea with source code. i want developer to copy same mt4 code and create mt5 EA
Gold hunter v5 30+ USD
*TITLE:* 5 Trades EA - EMA20/50 + RSI - Safe for Small Account *SPECIFICATION:* I need MT5 EA - Source Code .mq5 *Logic:* Buy: EMA20 > EMA50 and RSI(14) 45-70 Sell: EMA20 < EMA50 and RSI(14) 30-55 Timeframe M15, Symbol XAUUSD and all Forex *Trade Management:* Max 5 trades at same time. Fixed lot 0.01. No martingale. No lot increase. Distance between trades 150 points. Do not open all 5 at same price. Max 5 total
Investor Account (Read-Only Access) ‎ ‎📌 Platform: MT5 ‎📌 Broker: Fusion Markets Pty Ltd ‎📌 Server: Fusion Markets Demo ‎📌 Login: 422204 ‎📌 Investor Password: Gen@2026 please check this demo account, which strategy added here and understand how to work this robot. i need this kind trading robot. only expert developer needed. no need apply new developer. I will test robot in demo account, when we see bot
Poverty 30+ USD
Develop the EA according to my provided trading strategy and rules. The EA must open and close trades automatically according to the specified conditions. Include configurable Stop Loss, Take Profit, lot size and risk-management settings. Include an option for fixed lot size or percentage-based risk. Include Magic Number and trade-comment settings. The EA must work correctly on the requested MT4/MT5 platform and
I need an Expert Advisor (EA) developed for MetaTrader 5 (MT5) tailored for trading on Exness accounts. Account & Server Details: Trading Platform: MetaTrader 5 (MT5) Broker: Exness Execution Type: Market / Pending Orders Account Type: [Specify: Standard / Pro / Raw Spread / Zero] Target Instruments: [Specify pairs, e.g., XAUUSD, EURUSD, BTCUSD] Strategy Requirements: Entry Rules: [Insert your buy/sell entry
Monthly Report: August 2026 World PEACE Multi FX Algo generated a total realized profit of approximately 31,966 JPY during August. The provider account is normally operated with approximately 200,000 JPY of capital. Compared with this standard operating amount, the realized profit for August was approximately 15.98%. Please note that this is not a compounded monthly return. Realized profits are withdrawn regularly
I’m looking for an experienced developer who can build a Martingale trading bot. I’m willing to pay a fair price for the right developer. I have an example trading account that demonstrates exactly how I want the bot to operate. The strategy is straightforward: the bot trades continuously using a Martingale system. The only exception is that it should automatically pause trading during high-impact news events or
This is a Tradingview project. Would you be able to make this? With a win rate and profit factor and percentage made and profit made and max dd reached. How many modifications would I be able to do? Could there be a table that shows win percentage profit factor and trading window where trades shouldn’t be placed and follows the rules of the pdf How long would it take and would it work on ninjatrader also

Informazioni sul progetto

Budget
30+ USD