Lwma close: if color[1] != color[2]

Job finished

Execution time 13 minutes
Feedback from customer
Thank you for the quick work.
Feedback from employee
Thank you for the project. It was a pleasure working with you.

Specification

Hello, I'm looking for a programmer who knows the lwma indicator thoroughly. (mql5)

1, I have an mql5 EA that I start manually from the panel. I want the EA to only monitor the color change of the lwma indicator when the position is started. Only the lwma indicator color created from the data of closed candles is interesting. The color created from the unclosed - currently running - data is not interesting. So, if the lwma colors created during the last two closed candles do not match, the position should be closed.
color[1] != color[2] -- positionclose

2, I would like the EA to only take 1 position on a chart.

3, The magic number should be set so that it only closes a position on the chart where it was started.

Unfortunately, I can't extract the color data from the lwma indicator in the event of a color change.


I am attaching the lwma indicator and the EA.

The (close)program in the OnTick unit is not working.

Thanks


Files:

MQ5
lwma.mq5
9.1 Kb

Responded

1
Developer 1
Rating
(22)
Projects
28
7%
Arbitration
9
33% / 33%
Overdue
1
4%
Working
2
Developer 2
Rating
(1305)
Projects
1734
49%
Arbitration
55
67% / 16%
Overdue
38
2%
Free
3
Developer 3
Rating
(8)
Projects
9
33%
Arbitration
1
100% / 0%
Overdue
0
Free
4
Developer 4
Rating
(636)
Projects
1007
47%
Arbitration
33
36% / 36%
Overdue
99
10%
Working
Published: 6 codes
5
Developer 5
Rating
(162)
Projects
289
35%
Arbitration
18
22% / 61%
Overdue
43
15%
Free
6
Developer 6
Rating
(176)
Projects
188
46%
Arbitration
3
33% / 33%
Overdue
1
1%
Loaded
7
Developer 7
Rating
(39)
Projects
59
20%
Arbitration
6
33% / 17%
Overdue
1
2%
Working
Published: 2 codes
8
Developer 8
Rating
(274)
Projects
403
28%
Arbitration
40
40% / 50%
Overdue
1
0%
Free
9
Developer 9
Rating
(455)
Projects
721
34%
Arbitration
35
71% / 9%
Overdue
23
3%
Free
10
Developer 10
Rating
(323)
Projects
328
71%
Arbitration
2
100% / 0%
Overdue
0
Free
Published: 1 code
11
Developer 11
Rating
(209)
Projects
272
21%
Arbitration
24
54% / 17%
Overdue
0
Free
12
Developer 12
Rating
(35)
Projects
53
74%
Arbitration
4
50% / 0%
Overdue
0
Free
13
Developer 13
Rating
(319)
Projects
568
35%
Arbitration
82
30% / 45%
Overdue
206
36%
Loaded
14
Developer 14
Rating
(574)
Projects
945
47%
Arbitration
309
58% / 27%
Overdue
125
13%
Free
15
Developer 15
Rating
Projects
0
0%
Arbitration
0
Overdue
0
Free
16
Developer 16
Rating
(7)
Projects
7
0%
Arbitration
0
Overdue
2
29%
Free
17
Developer 17
Rating
(78)
Projects
246
74%
Arbitration
7
100% / 0%
Overdue
1
0%
Free
Published: 1 article
18
Developer 18
Rating
(617)
Projects
721
33%
Arbitration
46
48% / 41%
Overdue
14
2%
Loaded
19
Developer 19
Rating
(4)
Projects
8
0%
Arbitration
3
33% / 67%
Overdue
4
50%
Free
20
Developer 20
Rating
(453)
Projects
566
26%
Arbitration
24
42% / 38%
Overdue
85
15%
Free
Published: 6 codes
21
Developer 21
Rating
(2675)
Projects
3414
68%
Arbitration
77
48% / 14%
Overdue
342
10%
Free
Published: 1 code
22
Developer 22
Rating
(443)
Projects
570
37%
Arbitration
106
39% / 33%
Overdue
17
3%
Free
23
Developer 23
Rating
Projects
0
0%
Arbitration
0
Overdue
0
Free
24
Developer 24
Rating
Projects
0
0%
Arbitration
0
Overdue
0
Free
25
Developer 25
Rating
(7)
Projects
6
0%
Arbitration
4
25% / 75%
Overdue
2
33%
Free
26
Developer 26
Rating
(10)
Projects
14
43%
Arbitration
0
Overdue
3
21%
Free
Similar orders
Project Description I am looking for an experienced MQL5/MT5 Expert Advisor developer to develop an automated trading EA for XAUUSD on the M3 timeframe , running on an Exness account . The EA will automate a manual strategy based on SNR/GAP zones , using two setup types: Price Rejection Price Correction The EA should identify valid BUY/SELL setups around predefined SNR/GAP areas, apply configurable RSI, SMA, EMA and
I need an MT5 Expert Advisor for XAUUSD (Gold) running on an Exness account. STRATEGY LOGIC The exact entry and exit rules will be provided in writing before development starts. Please quote for a single rule-based strategy with clearly separated logic, so the rules can be adjusted later without rewriting the whole EA. RISK MANAGEMENT (this is the priority of the project) - Risk per trade as a percentage of account
Modification of Trade_Panel_7 7.05 Objective . I have this utility “Trade_Panel_7 7.05” with which I open and close positions. Please refer to attached “Trade Panel Modification.jpg”. It shows an input parameter “Volume Step”. This parameter has the initial value of 0.02 as shown. This feature needs to be amended. Present Status . Value of lot size is increased by this “Volume Step”. I have built a whole series of
Hello Traders, Have a trading strategy or idea you want to automate? I specialize exclusively in MQL5 development, helping traders turn their concepts into professional trading solutions. Custom Expert Advisors — automate your strategy and reduce manual execution Custom Indicators — transform your market ideas into powerful trading tools Fix & Debug — identify errors and get your existing code working properly
please share: Strategy description — entry/exit rules, indicators used, timeframe(s), and instrument(s) (a written explanation, screenshots, or an existing indicator/EA to reference all work) Risk management rules — position sizing method (fixed lot / % risk), stop loss / take profit logic, max drawdown or daily loss limits, and whether martingale/grid/hedging is involved Broker & account details — broker name
I need a unique grid trading system for XAUUSD that combines entry, controlled two-sided grid expansion, DCA (Dollar Cost Averaging) basket profit control, hedging. Unlike traditional grid EAs that only trade against price, this unique grid system should dynamically build positions in both directions based on market movement, allowing flexible adaptation to changing conditions ie the grid needs to dynamically move
I need an experienced MQL5 developer to create a fully automated MT5 Expert Advisor called Ayoub Gold EA , focused exclusively on XAUUSD (Gold) . Main requirements: Platform: MT5 / MQL5. Fully automated BUY and SELL trading on XAUUSD. Must support broker suffixes such as XAUUSD, XAUUSD.f and XAUUSDm. Trading strategy based mainly on Range Breakout with trend confirmation. EMA, ADX and ATR filters. London/New York
Mashiri 50 - 10000 USD
I need a custom MetaTrader 5 indicator designed specifically for XAUUSD gold trading. The indicator should identify potential buy and sell opportunities, display clear entry and exit signals on the chart, provide alerts, and help identify market trends and possible reversals
Looking for an experienced Sierra Chart ACSIL/C++ developer to customize an existing footprint chart. I need 3 things: 7-Day ATR – calculate and display a configurable 7-day ATR. Custom Footprint – modify my existing footprint chart to match my preferred layout/data display. Automatic LVN – detect and plot Low Volume Nodes automatically based on volume distribution. I already have a working footprint chart, so no
//———————————————————————————————————————————————————————————————————— struct S_MCAV { double matureSum; double totalSum; double value; void Init () { matureSum = 0.0; totalSum = 0.0; value = 0.5; } void AddContext (int ctx) { totalSum += 1.0; if (ctx == 1) matureSum += 1.0; } void ApplyDecay (double rate) { matureSum *= rate; totalSum *= rate; } void Update () {

Project information

Budget
30 - 60 USD