Specifiche
I first explain the strategy, and then I set up an artificial trading case
1) Market BUY Order comes from the Telegram copier looking like 0.02 lot with Take Profit set to 4 pip, and StoppLoss set to 30 pip.
2) This trigger our new EA that you are programming now to set up to 5 new orders (Quentity to be programmable for me in the EA properties - 1 to 5 orders), all these orders with size 4 pip (To be programable in the EA properties), These 5 orders are to be set just after each other so that next order of this group takes over when the first order goes to TP.
and each of these up to 5 orders have their own TP of 4 pip and its own SL of 30 pip. (To be programmable for me in the EA properties).
3) When any of these orders during their “trading life” hits their set StoppLoss, all of the orders connected to this order; 1 to 5 orders (open order and not yet opened orders) will close.
A “live” study:
1) Incoming XAUUSD BUY Market order from Telegram, at 2700.00 TP set at 2700.40 and StoppLoss set at 2697.00
2) Our new EA detects this, and act at once by setting up 5 new pending orders at:
At 2700.40 at 2700.80 at 2701.20 at 2701.60 at 2702.00
These 5 orders have StoppLoss: at 2697.40 at 2697.80 at 2698.20 at 2698.60 at 2699.00
These 5 orders have Take Profit at: at 2700.80 at 2701.20 at 2701.60 at 2702.00
3) When market goes on, it will reach the TakeProfit of the Order incoming from the Telegram copier at 2700.40
and a new order will at the same time opens at 2700.40 (Our first set order from our new EA out of 5 orders).
Now this new order goes to TP at 2700.80 or it goes to SL at 2697.40
If it goes to SL at 2697.40, all passive as well as this active order will close.
If it goes to TP at 2700.80, a new order number 2 of 5 orders will be opened at 2700.80
4) The sequence will repeat, as now the newly opened order 2 from the EA is open.
This new order either goes to hit TP at 2701.20 where a new order will be created as listed here above.
Or it goes to SL at 2697.80 with the result that our EA closes all trades (these open trades as well as all pending trades connected to this order.
5) This order handling will repeat itself 5 times with 5 orders from this new EA, and after that this order is finished.
Best regards
Erik