Close current ordem and open new order inverse position.
-
Hello friends of fxdreema, I hope everyone is making a lot of gains.
I would like some help.
How do I open a new position as opposed to the position that is going towards the stop loss direction?Example:
- My EA opened a 100 pips stop buy order with 50 pips take profit
- When the price goes in the opposite direction I would like towards the Stop loss and reaches 30 pips I want to open a reverse sell order with 100 pips stop loss and 50 pips take profit and close out previously opened.
-
Firstly you need to identify there is an open trade right now. That you can do with an 'If trade' block. Then you need to identify there is a loss right now. You can do it with the pink blocks, headed by a 'For each trade'. Finally yo will need a 'close trade' when those conditions are met and an opposite buy/sell block to open the new trade.
-

is this the setting or am i doing something wrong?
-
I need to see how blocks are set. Could you please share a link with the project?
-
https://fxdreema.com/shared/spvpbvwue my project
-
I see. Ok. Firstly, you are working on candle ID 0 everywhere. I strongly recommend you to do it on candle ID 1 in all operands of all your condition blocks (clock on 'More settings').
Secondly, disconnect all blocks below buy/sell now. They should be the last ones of their tree. Then create a new separate tree of blocks headed by 'For each trade'. Below then you can connect all required conditions to close your trades.
Try it and let me know.