But sometimes I get this (the 2nd Vline should not be there):
I don't see a problem with your picture . . . . assuming I understand what you are trying to do.
Let me explain . . .
When the 1st order has opened it is the oldest so it gets marked with an Aqua line . . . then the 2nd order opens, the 1st is still the oldest so no new aqua line is drawn. Then the 3rd order opens and the 1st is still the oldest . . no new aqua line is drawn. The 3rd trade closes. Then the 1st order closes . . . at this point in time the 2nd order is now the oldest open order so it gets marked with an aqua line . . . shortly after this it to closes.
Damn you're right! I was thinking along a linear time line and it didn't strike me that a marker could be placed back in time.
Thanks!
Damn you're right! I was thinking along a linear time line and it didn't strike me that a marker could be placed back in time.
Thanks!

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
Hi, I need to point out the first long order that occurs after a pause of no open long orders (this EA trades multiple orders in the same direction).
The code below tries to find this order, and put a marker on it (for debugging) .
The EA places its trades as usual, and in the Start function I call:
bool dummy = FirstInRow();
This should be pretty simple, and the code below gets it right most of the time, but sometimes it does not... Why ?
This is what it looks like when correct:
But sometimes I get this (the 2nd Vline should not be there):