MT5 Expert Advisor: Buy/Sell Based on Previous Candle Color (MQL5)

MQL5 专家

指定

Write an MQL5 Expert Advisor (EA) for MetaTrader 5.

Trading logic:
- On each new bar, check the last closed candle.
- If the candle is bearish (close below open), open a SELL.
- If the candle is bullish (close above open), open a BUY.
- If open equals close (doji), do nothing.

Inputs (adjustable by the user):
- Lot size
- Stop Loss in points
- Take Profit in points
- Maximum number of open positions allowed
- Magic number

Rules:
- Do not open a new trade if the maximum number of positions is already reached.
- Include only these features. No extra indicators, filters, or unnecessary options.
- Keep the code short, clean, and easy to read, with brief comments.
- Use the standard CTrade class.

Output:
- Provide the full .mq5 source code, ready to compile in MetaEditor and to publish on mql5.com.

反馈

1
开发者 1
等级
(642)
项目
750
35%
仲裁
50
52% / 38%
逾期
14
2%
工作中
2
开发者 2
等级
(295)
项目
368
30%
仲裁
37
27% / 65%
逾期
10
3%
工作中
发布者: 10 代码
3
开发者 3
等级
(64)
项目
145
46%
仲裁
21
38% / 24%
逾期
32
22%
空闲
4
开发者 4
等级
(469)
项目
823
49%
仲裁
76
21% / 51%
逾期
143
17%
工作中
5
开发者 5
等级
(637)
项目
1009
47%
仲裁
33
36% / 36%
逾期
99
10%
工作中
发布者: 6 代码
6
开发者 6
等级
(62)
项目
90
29%
仲裁
24
13% / 58%
逾期
7
8%
工作中
7
开发者 7
等级
(111)
项目
184
25%
仲裁
25
16% / 76%
逾期
16
9%
空闲
8
开发者 8
等级
(24)
项目
32
38%
仲裁
4
50% / 25%
逾期
5
16%
工作中
9
开发者 9
等级
项目
0
0%
仲裁
0
逾期
0
空闲
10
开发者 10
等级
(5)
项目
7
86%
仲裁
0
逾期
0
空闲
发布者: 4 代码
11
开发者 11
等级
(1)
项目
1
100%
仲裁
0
逾期
0
工作中
发布者: 7 代码
12
开发者 12
等级
(11)
项目
19
21%
仲裁
3
0% / 67%
逾期
3
16%
已载入
13
开发者 13
等级
(191)
项目
205
47%
仲裁
4
50% / 25%
逾期
1
0%
已载入
14
开发者 14
等级
(61)
项目
61
51%
仲裁
1
0% / 100%
逾期
1
2%
空闲
15
开发者 15
等级
项目
0
0%
仲裁
0
逾期
0
空闲
16
开发者 16
等级
(9)
项目
11
73%
仲裁
0
逾期
0
工作中
发布者: 1 文章, 2 代码
17
开发者 17
等级
(1)
项目
1
0%
仲裁
0
逾期
0
空闲
发布者: 4 代码
18
开发者 18
等级
项目
0
0%
仲裁
0
逾期
0
空闲
19
开发者 19
等级
(1)
项目
1
100%
仲裁
0
逾期
0
空闲
20
开发者 20
等级
项目
0
0%
仲裁
0
逾期
0
空闲
发布者: 2 代码
21
开发者 21
等级
(1)
项目
4
50%
仲裁
3
0% / 100%
逾期
2
50%
空闲
发布者: 4 代码
22
开发者 22
等级
(4)
项目
5
60%
仲裁
0
逾期
1
20%
空闲
23
开发者 23
等级
(568)
项目
866
61%
仲裁
33
27% / 45%
逾期
24
3%
空闲
发布者: 1 代码
24
开发者 24
等级
(2)
项目
3
33%
仲裁
0
逾期
2
67%
工作中
25
开发者 25
等级
(25)
项目
35
40%
仲裁
9
22% / 33%
逾期
5
14%
已载入
发布者: 9 文章, 35 代码
26
开发者 26
等级
(4)
项目
11
55%
仲裁
1
100% / 0%
逾期
0
空闲
27
开发者 27
等级
(2)
项目
3
33%
仲裁
0
逾期
2
67%
空闲
28
开发者 28
等级
(45)
项目
63
52%
仲裁
5
0% / 40%
逾期
1
2%
空闲
29
开发者 29
等级
项目
0
0%
仲裁
0
逾期
0
空闲
30
开发者 30
等级
(1)
项目
1
0%
仲裁
0
逾期
0
空闲
31
开发者 31
等级
项目
0
0%
仲裁
0
逾期
0
空闲
发布者: 7 代码
32
开发者 32
等级
(268)
项目
319
74%
仲裁
16
75% / 0%
逾期
6
2%
工作中
33
开发者 33
等级
项目
0
0%
仲裁
0
逾期
0
空闲
发布者: 1 代码
34
开发者 34
等级
项目
0
0%
仲裁
0
逾期
0
空闲
发布者: 2 代码
35
开发者 35
等级
(3)
项目
4
0%
仲裁
1
0% / 100%
逾期
0
空闲
36
开发者 36
等级
项目
0
0%
仲裁
0
逾期
0
空闲
37
开发者 37
等级
(60)
项目
96
43%
仲裁
4
0% / 100%
逾期
4
4%
空闲
38
开发者 38
等级
(1)
项目
1
0%
仲裁
1
0% / 100%
逾期
0
空闲
39
开发者 39
等级
(2)
项目
2
50%
仲裁
0
逾期
1
50%
空闲
40
开发者 40
等级
项目
0
0%
仲裁
0
逾期
0
空闲
发布者: 5 代码
41
开发者 41
等级
(2354)
项目
2960
63%
仲裁
125
44% / 26%
逾期
429
14%
工作中
相似订单
--- I need an MT5 Expert Advisor (EA) for Forex trading. Strategy: - Trade when fast Moving Average (9) crosses above slow Moving Average (21) = BUY - Trade when fast Moving Average (9) crosses below slow Moving Average (21) = SELL - Only 1 trade at a time Settings I want to change: - Lot size - Stop Loss in pips - Take Profit in pips - Trailing Stop - Trading hours (Start and End time) Risk: - Close all trades at
ICC SMART STRUCTURE EA 50 - 100 USD
DEVELOPMENT REQUIREMENTS Project Title: ICC Smart Structure EA – MT5 Automated Trading System 1. Project Objective I want a fully automated Expert Advisor (EA) for MetaTrader 5 (MT5), based on my Indication–Correction–Continuation (ICC) trading strategy. The EA must identify market structure, Break of Structure (BOS), swing highs and lows, supply and demand zones, corrections and continuation entries across multiple
The EA is already developed and functional, but there are some issues with its current behaviour that need to be investigated and corrected. **Requirements:** - Review the existing EA source code and identify the root cause of the issues. - Fix the existing problems without affecting other working functionalities. - Ensure the EA operates correctly under different market conditions. - Maintain the existing trading
Project Description I am looking for an experienced MQL5 developer with strong knowledge of FIX Protocol (Financial Information Exchange) to integrate FIX API connectivity into an existing MetaTrader 5 Expert Advisor. The main objective is to improve order execution speed, reduce execution latency, and minimize slippage, especially for high-frequency scalping strategies. Required Features 1. Integrate FIX Protocol
I want reading tradingviwer signal and want open mt5 account trades. Want reading stop loss size and take a profit size and when signalClosing ! This ea want cancel open trades
a { text-decoration: none; color: #464feb; } tr th, tr td { border: 1px solid #e6e6e6; } tr th { background-color: #f5f5f5; } I’m looking for a developer to create a fully automated trading bot (Expert Advisor) for MT5. I am not an expert trader, so the bot should have its own trading strategy, scan the market automatically, identify trading opportunities, and place buy/sell trades without manual input. It should
برمجة روبوت تداول MQL5 بهدف 50 نقطة مع إدارة مخاطر.مطلوب برمجة خبير تداول آلي يعمل على منصة MQL5، يركز على تحقيق هدف 50 نقطة مع إدارة صارمة للمخاطر وتحديد وقف الخسارة
I want full experience devloper need , I want devlope 4 Type Bot , Grd strategy 2 , and other bias strategy 2 scaning on market condition choose one order buy or sell and take profit and target fully automatic management, I am explain full details on private chat only experience developer contact me
Hello everyone, I am a final-year AI & Data Science student interested in building a career in algorithmic trading and EA development. I have good technical knowledge of MQL5, MT5 Expert Advisors, risk management, technical indicators, and automated trading strategies. I have also worked on building trading systems using Machine Learning and Neural Networks. I know how to develop EAs and trading strategies, but I am
Hello! I don't have time, but I bought some challanges and honestly I don't feel 100% confident yet for trading, I am eager to share prop firm account with good, profitable trader. 50% of profits are your, but first I need to make selection, I need to trust you somehow that you will not blow up account within few days. Only serious persons please, please don't waste me time and yours

项目信息

预算
70 - 100 USD
截止日期
到 10 天

客户

所下订单1
仲裁计数0