Why does the boolean block not open the sell order in the EA below
-
-
@od What boolean block?
-
@jstap In the modify variable block I've created a variable to store the open price level of the buy trade then in the condition block if the variable is same as current open price a sell should open. But it seems not to work that way.
-
@od Boolean is true or false, i assume that variable is a double, your condition is always correct because they both get the same value.
-
@jstap I wanted to place a sell order at the same price as the buy opening price.
-
@jstap How else can the open price now be compared to the buy open price so that if they are equal a sell is opened. This one is part of a grid system where I want to buy and sell at the same time.
-
@od If every time, tee off the buy so it places a sell at the same time, alternatively market properties x<> open price.
-
@jstap Kindly if possible create an example
-
@od Here is a couple of examples.
: -
@jstap Thanks for the example but in testing it could miss a trade or enter so much later. In this algo it should be nearly same price but most importantly same time.
-
@jstap I have these idea in the same EA where there will always be group (2) trades each 20 pips apart. My structure in block (16&23) only works the first time then it loses logic. How is it possible to open only one group (2) trade when price is retesting grid levels that already opened trades and group 2 trades are in existence at these levels.https://fxdreema.com/shared/hXJ8NAH2d
-
@od This is one thing I can't help you much with, haven't tried for a long time but I never got on well with the no order nearby blocks.
-
@jstap Might you have another suggestion ? It doesn't have to be the exact way I put it...is there a way to uniquely identify each trade apart from using group numbers
-
@od In the pink blocks you have pips away, you also have the option to only allow once per trade, or you can set for parent trade or current partial trade. One of these options should work but I have not used them much, I would setup a small project so I could back test each option, and find the one that works best for my needs.