Modify to an Existing EA

MQL4 Integration

Job finished

Execution time 1 day
Feedback from customer
Nice to work with, and got the time to understand it. Great.
Feedback from employee
thank you

Specification

I need a coder to make this rule for me, so I can integrate it in my EA.

The strategy  is to count from last Orders open price,

if price goes up X-pips, it opens a BUY (POS1), then  if price goes down X-pips,  it opens a SELL (POS2).

So far so good.


But then if the price goes up again X-Pips, it would open again at the same price as the existing opened BUY, but we want it to go further up from here the X-Pips before it  is allowed to open a BUY (POS3).
If the existing Opened BUY is more than 2 positions away, it is allowed to open the BUY at the same price.

 

//=========== Code

  int tick=GetLastPositionTicket();   

  if(OrderSelect(tick,SELECT_BY_TICKET) && GVGet("Stopped")==0 && GVGet("Start")==1)

    {

      if((OrderOpenPrice()-Bid)/(Point*P)>Distance_Down)sell=true;     

      if((Ask-OrderOpenPrice())/(Point*P)>Distance_Up)buy=true;

    }

 

//==============   

Responded

1
Developer 1
Rating
(41)
Projects
160
45%
Arbitration
16
13% / 50%
Overdue
48
30%
Free
2
Developer 2
Rating
(271)
Projects
553
50%
Arbitration
57
40% / 37%
Overdue
227
41%
Working
3
Developer 3
Rating
(473)
Projects
1139
44%
Arbitration
51
31% / 33%
Overdue
501
44%
Free
4
Developer 4
Rating
(12)
Projects
17
35%
Arbitration
1
0% / 100%
Overdue
3
18%
Free
5
Developer 5
Rating
(499)
Projects
744
56%
Arbitration
48
31% / 31%
Overdue
120
16%
Free
Published: 1 code
6
Developer 6
Rating
(47)
Projects
140
49%
Arbitration
9
56% / 0%
Overdue
27
19%
Free
7
Developer 7
Rating
(49)
Projects
134
27%
Arbitration
62
13% / 53%
Overdue
58
43%
Free
Published: 331 articles, 1 code

Project information

Budget