Select last 30 orders in history with magic number 999999 MQL4

MQL4 Uzmanlar Komut dosyaları

İş tamamlandı

Tamamlanma süresi: 3 dakika
Müşteri tarafından geri bildirim
Compliments to Ivand for his work. His work was quick, accurate for a reasonable price. He also helped me with the running of the script. Would definitely recommend him as a EA programmer to others.

Şartname

Hallo,

I want to select the last 30 orders form my EA with the magicnumber 999999  in MQL4. Currently my code is like this which doesnt account for the MagicNumber:

OrderSelect(OrdersHistoryTotal()-30,SELECT_BY_POS,MODE_HISTORY);  
   double G30 = OrderProfit();                                       if(G30 > 0) W ++;  
   if(G30 == 0) G30 = 0.0001; 
   if(G30 > 0) Wins = Wins + G30; 
   if(G30 < 0) Loss = Loss + G30;
   OrderSelect(OrdersHistoryTotal()-29,SELECT_BY_POS,MODE_HISTORY);  
   double G29 = OrderProfit();                                       if(G29 > 0) W ++; 
   if(G29 == 0) G29 = 0.0001; 
   if(G29 > 0) Wins = Wins + G29; 
   if(G29 < 0) Loss = Loss + G29;               
   OrderSelect(OrdersHistoryTotal()-28,SELECT_BY_POS,MODE_HISTORY);  
   double G28 = OrderProfit();                                       if(G28 > 0) W ++;        
   if(G28 == 0) G28 = 0.0001; 
   if(G28 > 0) Wins = Wins + G28; 
   if(G28 < 0) Loss = Loss + G28;     

 I want to select the last 30 orders from the ea with the magicnumber 999999 and than calculate the average winn and  average loss amount of the last 30 trades.

Can anybody help me?

Kind Regards

 

Rene  

Yanıtlandı

1
Geliştirici 1
Derecelendirme
(647)
Projeler
1295
67%
Arabuluculuk
84
26% / 49%
Süresi dolmuş
337
26%
Serbest
2
Geliştirici 2
Derecelendirme
(182)
Projeler
342
42%
Arabuluculuk
118
12% / 73%
Süresi dolmuş
104
30%
Serbest
Yayınlandı: 4 kod
3
Geliştirici 3
Derecelendirme
(2676)
Projeler
3418
68%
Arabuluculuk
77
48% / 14%
Süresi dolmuş
343
10%
Çalışıyor
Yayınlandı: 1 kod
4
Geliştirici 4
Derecelendirme
(14)
Projeler
27
22%
Arabuluculuk
18
6% / 89%
Süresi dolmuş
8
30%
Serbest
Yayınlandı: 1 kod
5
Geliştirici 5
Derecelendirme
(618)
Projeler
1429
59%
Arabuluculuk
31
81% / 0%
Süresi dolmuş
10
1%
Serbest
6
Geliştirici 6
Derecelendirme
(88)
Projeler
143
39%
Arabuluculuk
21
19% / 48%
Süresi dolmuş
30
21%
Serbest
7
Geliştirici 7
Derecelendirme
(1931)
Projeler
3552
88%
Arabuluculuk
73
40% / 15%
Süresi dolmuş
268
8%
Serbest
8
Geliştirici 8
Derecelendirme
(16)
Projeler
39
69%
Arabuluculuk
2
0% / 50%
Süresi dolmuş
1
3%
Serbest
9
Geliştirici 9
Derecelendirme
(453)
Projeler
566
26%
Arabuluculuk
24
42% / 38%
Süresi dolmuş
85
15%
Serbest
Yayınlandı: 6 kod
10
Geliştirici 10
Derecelendirme
(174)
Projeler
233
61%
Arabuluculuk
3
33% / 33%
Süresi dolmuş
6
3%
Serbest
Yayınlandı: 1 kod
11
Geliştirici 11
Derecelendirme
(70)
Projeler
86
31%
Arabuluculuk
1
100% / 0%
Süresi dolmuş
1
1%
Serbest
12
Geliştirici 12
Derecelendirme
(12)
Projeler
13
31%
Arabuluculuk
1
0% / 100%
Süresi dolmuş
1
8%
Serbest
Yayınlandı: 1 kod
13
Geliştirici 13
Derecelendirme
(47)
Projeler
140
49%
Arabuluculuk
9
56% / 0%
Süresi dolmuş
27
19%
Serbest
14
Geliştirici 14
Derecelendirme
(14)
Projeler
22
27%
Arabuluculuk
24
13% / 79%
Süresi dolmuş
6
27%
Serbest
15
Geliştirici 15
Derecelendirme
Projeler
0
0%
Arabuluculuk
0
Süresi dolmuş
0
Serbest
16
Geliştirici 16
Derecelendirme
(64)
Projeler
144
46%
Arabuluculuk
21
38% / 24%
Süresi dolmuş
32
22%
Çalışıyor
Benzer siparişler
Hi, I need an Expert Advisor (EA) for MetaTrader 5, for my IC Markets account. Account MT5, hedging account, type: [Raw Spread / Standard: fill in] Deposit: 100 USD, leverage 1:30, account currency: [USD / EUR: fill in] Instruments Forex (major pairs) and gold (XAUUSD) Strategy and parameters may differ per instrument; each instrument must be tested and optimized separately If an instrument cannot be traded safely
المطلوب موشر لتداول الذهب مجرب وقوية يعطي اشاره قوية فقط مع وقف خساره ومختبر ومجرب في حال الموافقه علي لموشر بعد التجربه لمدة ٣ ايام يتم الشراء دايم مبلغ ٢٠٠ دولار
Masoudahg1 999999+ USD
Hello world, thank you for your helping and supporting for us from your for all everyone that investments or working in this programing and supporting seven/24 hours in daily and nightly for customers
Laily Mahmudy 100000+ USD
Thank you very much and of trying supporting and helping for us and my investfolio portfolio id is:"investfolio portfolio masoudahg1 id is":"7Zk0iVh7zuytHkQ9OJSzeY" &"35VmgKWofZxWowQ7O6CL8K" https://leylimahmudi46.atlassian.net is my Atlassian programing that when I working of this programs
Hi there I need someone who will create an ea then test it .. the ea should only place order on the bid price of it breakout in 1 point using invisible buy and invisible sell,, example if bid breakout in 1 point up automatically invisible buy active then invisible stop loss at where the ask price was same in sell If the bid breakout in 1 point down automatically invisible sell active then invisible stop loss where
I’m looking for an experienced MT5/MQL5 freelancer to help install and configure several existing EAs on IC Markets MT5 accounts using a Windows VPS. The work will include setting up the EAs on separate demo accounts and later running several together on one account with different risk settings. I also need help with MT5 backtesting and strategy optimisation, including comparing different risk levels and reviewing
I am looking for someone to build me a modular auto trader in Sierra chart and an Innie builder so that I can replicate my current Algas that I already have built. I've sent examples below can you please let me know how much you would charge me. I'm pretty good at building the signals myself but I do not know how to build the ocos order entry and I'm trying to get quotes and go with the person who seems they can help
i need price action and candle logic understand programmer need for this job... first understand logic and interested please message .... first understand logic and interested please message .... 2 types of hedge entry conditions: 1 is candle based 1- when i start point ea hh candle buy entry, after ll made 2- below the previous candle hedge sell order 3- if market goes again hh, if sell order profit book again
Ea which is based on the price returning to the open or close of a 1-minute candle or zone of candles. panel on chart need too have buttons : trainding on/off close all close profit add buy stop add buy limit add sell stop add sell limit ( all to existing setups) calculating profit/loss for a single open setup and in total in account currency calculating profit/loss for a single open setup and in total in percentage
Hi, I’m looking for an experienced MQL5/MT4 developer to work on a trading BOT project. I currently have an MT4 demo environment with IC Markets for testing, but the complete strategy specifications have not yet been provided. I’d like you to first review the available project/BOT information and let me know what you would need to configure, develop, and properly forward-test it. The testing should cover entries

Proje bilgisi

Bütçe
10 - 25 USD