AN EXPERT BASED ON PENDING BUY STOP AND SELL STOP ORDERS

Specification

This is a MQL4 trading robot code that seems to implement a basic grid trading strategy. It opens two pending orders (a BuyStop and a SellStop) for a specified symbol when the current server time matches the specified trading time. It then modifies the stop loss and take profit of each order based on their type (BuyStop or SellStop). The lot size of each order is calculated using a risk percentage (RiskPercent) and the free margin available in the account.

Here are some of the important variables and functions used in this code:

Variables:

  • BuyPips: the distance in pips between the BuyStop and the current market price
  • SellPips: the distance in pips between the SellStop and the current market price
  • RiskPercent: the risk percentage used to calculate the lot size of each order
  • Ntokozo: a string variable used to display a comment on the chart
  • TradingTime: the time when the robot should start trading
  • ContractSize: the contract size used to calculate the lot size of each order
  • maxPendingOrders: the maximum number of pending orders that can be opened for each symbol
  • pendingOrdersCount: an array that keeps track of the number of pending orders for each symbol
  • symbolInitialized: a boolean array that keeps track of whether each symbol has been initialized or not

Responded

1
Developer 1
Rating
(19)
Projects
26
27%
Arbitration
3
0% / 100%
Overdue
2
8%
Free
2
Developer 2
Rating
(2)
Projects
5
0%
Arbitration
1
0% / 100%
Overdue
0
Working
3
Developer 3
Rating
(37)
Projects
59
27%
Arbitration
26
19% / 54%
Overdue
10
17%
Working
Published: 1 code
4
Developer 4
Rating
(6)
Projects
10
50%
Arbitration
6
17% / 50%
Overdue
3
30%
Working
5
Developer 5
Rating
(85)
Projects
169
44%
Arbitration
3
67% / 0%
Overdue
5
3%
Working
Published: 1 code
6
Developer 6
Rating
(568)
Projects
641
41%
Arbitration
25
48% / 36%
Overdue
46
7%
Working
7
Developer 7
Rating
(45)
Projects
46
24%
Arbitration
34
9% / 85%
Overdue
10
22%
Free
8
Developer 8
Rating
(3)
Projects
4
0%
Arbitration
2
0% / 100%
Overdue
1
25%
Free
9
Developer 9
Rating
(296)
Projects
475
40%
Arbitration
105
40% / 24%
Overdue
80
17%
Busy
Published: 2 codes
10
Developer 10
Rating
(72)
Projects
80
10%
Arbitration
38
8% / 58%
Overdue
6
8%
Free
11
Developer 11
Rating
(271)
Projects
553
50%
Arbitration
57
40% / 37%
Overdue
227
41%
Working
12
Developer 12
Rating
(144)
Projects
186
41%
Arbitration
24
58% / 21%
Overdue
13
7%
Free
13
Developer 13
Rating
(44)
Projects
53
38%
Arbitration
8
13% / 38%
Overdue
8
15%
Working
14
Developer 14
Rating
(87)
Projects
131
22%
Arbitration
7
57% / 0%
Overdue
33
25%
Free
Published: 1 code
15
Developer 15
Rating
(6)
Projects
8
25%
Arbitration
1
100% / 0%
Overdue
3
38%
Free
16
Developer 16
Rating
(450)
Projects
477
69%
Arbitration
6
67% / 0%
Overdue
2
0%
Free
Similar orders
Hello, I am looking for a professional programmer to build an EA that can be able to take trades effectively in the correct direction with adequate indices that can help to predict the market move in advance. The EA will also be able to manage multiple trades to ensure that profits activated are closed before any major market reversals. The EA will have a maximum of 3 price indices at the start, and then the
The scanner will scan all currency base on MACD Diverdgent, my strength indicator and my better volume indicator. All this would be across all time frame and all currency pairs
Ninjatrdaer Script 500 - 1000 USD
I am looking to purchase a ninjatrader script, if there is any for sale, i mean a ready made ninjatrdaer script that trade futures, i need the seller to show me a backtest of the system, you know send some results, I would like to see a 1 year and YTD backtest
I will like to purchase tradingview strategy with high winning rate, i mean already made, tested and trusted and powerful strategy, i have tried to code my own strategy with lot of freelancers but nothing to me i am just wasting money, i have wasted lot of money already, so i need a high winning rate tradingview strategy, we can discuss price in chat, I will need to see some test result as well
Pakayaku Robot Trading 30 - 200 USD
Revolusi Trading BTCUSD dengan Presisi Fibonacci & Ichimoku Kumo "Memperkenalkan Pakayaku Robot Trading , asisten cerdas yang dirancang khusus untuk menaklukkan pasar emas (XAUUSD) dan Bitcoin (BTCUSD). Menggabungkan algoritma Fibonacci Retracement untuk akurasi titik pantul dan Ichimoku Kumo sebagai filter tren global. Mengapa Memilih Pakayaku? Analisa Multi-Indikator: Menggabungkan Fibonacci, Ichimoku, dan
Mk 30+ USD
I need a fully automated trading robot designed to generate consistent profits while strictly controlling risk and minimizing losses. The robot should use a combination of strategies, including trend-following, scalping, and price action, and must be able to adapt to different market conditions such as trending and ranging markets. It should analyze the market using indicators like Moving Averages, RSI, MACD, and
1. IF price forms: - Higher highs + higher lows → TREND = BUY - Lower highs + lower lows → TREND = SELL ELSE → NO TRADE 2. IF: - Trend = BUY - Price retraces to support zone - Bullish engulfing candle forms - TDI green crosses above red (optional) THEN: - Execute BUY 3. IF: - Trend = SELL - Price retraces to resistance - Bearish engulfing forms - TDI confirms THEN: - Execute SELL 4. Risk per trade = 1% of account Lot
Apply with a screen of your work . Symbol Specific Logic . Live Chart Optimization Check the Core logic . [back tests as well] Change points to pips . Create buffer for the zone
Hi, I am looking for an Quant/MQL5 developer to build a pure mathematical, Delta-Neutral Statistical Arbitrage (spot vs future ) Expert Advisor. ​ No retail indicator logic (No RSI, MACD, etc.). This is a high-speed, spread-based execution model trading the pricing inefficiency between two correlated assets (e.g., Gold Spot XAUUSD vs Gold Futures). ​ Core Requirements at a Glance: ​Real-time Spread & Z-Score
Looking for a Proven Non-Repainting Gold Indicator (XAUUSD) – High Accuracy & Ready-Made Solutions Only 📌 Project Description: I am looking for a high-quality, non-repainting indicator specifically for XAUUSD (Gold) that is already developed and tested. ⚠️ Important: I am NOT looking for a new indicator to be built from scratch. I want an existing, proven system that you have already created and are confident in. 🎯

Project information

Budget
30 - 50 USD
Deadline
from 1 to 2 day(s)