Hello,

could anybody of the competent coders in this forum write me a simple ea?

One thing it must do would be:

Scan the open positions (one pair only, long and short) and close positions having a positive difference in pips (this difference ought to be a variable input).

Example:

Bundle ( 10 Pips)

4 open positions

1 buy 10 Pips currently
1 buy -30 Pips currently
1 market 0 Pips currently
1 market -20 Pips currently


The ea must now close the very first buy and the first sell as these differ 10 Pips.


Would be very great if anybody could code this.

Thank you

Michael