Help me!! code!! open order

 

I want to open orders at the bar closed.

thank you.

 
You can't !
 

do you need open order at the end of bar accurately?? My opinion, why dont you open order at next bar's open, they are pretty much the same price.

or You also can try set the time to place your order, like in period 1H, you place order only at 59mins:59second. Hope I did not get your idea wrong.

 
Pain:

do you need open order at the end of bar accurately?? My opinion, why dont you open order at next bar's open, they are pretty much the same price.

or You also can try set the time to place your order, like in period 1H, you place order only at 59mins:59second. Hope I did not get your idea wrong.


you don't know if there comes a tick last second so take a second of 10 before ending bar .... if you wanna take that method
 
lafanoom:

I want to open orders at the bar closed.

thank you.

In time, previous closed bar is next opened bar.
 
thx
 
Whats the strategy behind it candlesticks or what? The best way is to open when the current bar has just opened using iclose(...,1) to find the close of the previous bar but you'll need to include a condition to decide wether to buy or sell.
Reason: