Hi everyone,
Before the weekend starts, I wanted to ask anyone here how to code (with DEFPARAM Cumulateorders = true) increasing orders every 3 pips.
Right now, I have coded it, and it open new orders every 3 pips, but start at the beginning of the next candle. Since I am working on large TFs (30 min, 1 hour), I would like to know the exact coding trick so I can open new orders in the same candlestick right after 3 pips.
Right now is:
IF LONGONMARKET AND Close-TRADEPRICE(1)> 3*pipsize AND MAXCONTRACTS THEN
BUY 1 CONTRACTS AT MARKET
ENDIF
I understand that “AT MARKET” will open the order at the opening of next candle (regardless is long or short), but I have tried changing it with other formulas and doesn`t work.
I would appreciate any suggestions.
Many thanks and have a great weekend,
Juan