no pending orders nearby
-
Hi, im building a system that places pending orders at specific levels. I only want to place new pending orders above or below existing pending orders if the distance is more than x pips between the new and any already existing pending order. The block called "no pending order nearby" does not seem to work for this requirment.
My idea is to store the price value of pending orders into variables, and make conditions that say that the pips distance has to be X or larger.
A few questions:
1: Is this a good way of doing it, or is there a better way?
2: How can i store the price values of opened pending orders in a variable?
3: What if I have 3 or 4 pending orders. Will I need to save each price value into its own variable?Cheers
-
@piptheripper Is the distance between pending orders always the same?
-
Sorry for the late reply. No the distance is not always the same. The pending orders are placed at swing highs or swing lows. I want to create a rule that says, "if there is a Pending order x or less pips above or below the price level where the ea wants to place the next pending order, then do not place new pending order. I hope its clear what im trying to do?
-
@piptheripper Then the standard 'no pending order nearby' should do the trick. You just need to be sure you are selecting the correct group numbers:

This blcosk is searching for all active pending orders right now so ther is no need to store theur values into variables.