Function which calculates how much money is engaged by a total of all trades

2019.09.13 Experts Scripts

Specification

I got a simple expert (This is the MovingAverage.mq4) provided by MT4, which can not loose more than 20% if the account. 

context : 

Balance is 10000 Euros / Currency Euro

pair EURUSD

Leverage 1:200

You need to write a new function which calculates how much money is engaged by a total of all trades (from a same expert ) and displays an alert

means, if the expert looses 2000 euros, the expert must stop immedialty


Important:

**** do not use those following functions as BalanceEquity or MarginFree, or MarginRequired or whatever.

Just, calculate the amount of money for each trade with OrderProfit(), OrderLots() , OrderOpenPrice() ..

 







Responded

1
Developer 1
2019.09.13
Rating
0
Projects
0
0%
Arbitration
0
Overdue
0
Free
2
Developer 2
2019.09.13
Rating
5
(4)
Projects
5
0%
Arbitration
1
0% / 100%
Overdue
2
40%
Working
3
Developer 3
2019.09.13
Rating
4.96
(364)
Projects
408
36%
Arbitration
36
22% / 53%
Overdue
75
18%
Busy
4
Developer 4
2019.09.13
Rating
4.9
(577)
Projects
757
39%
Arbitration
39
5% / 56%
Overdue
123
16%
Working

Project information

Budget
30+ USD
VAT (20%): 6 USD
Total: 36 USD
For the developer
27 USD
Deadlines
from 1 to 4 day(s)

Customer

Placed orders24
Arbitrage count3