I would like my strategy to place multiple order entries at certain increments within a certain price range.
Now, I can go ahead and code these order entry lines one by one with all the specific order prices and signal names etc, but is there also a way to do it in a loop?
I want to do something similar to the below code, but sofar the strategy analyzer keeps hanging in the loop and does not execute a single order:
// Set 1
if (Longs == true)
{
while (StopPrice >= StartRange && StopPrice <= EndRange)
{
StopPrice = StartRange + OrderIncrement;
EnterLongStopMarket(Convert.ToInt32(DefaultQuantity), StopPrice, StopPrice.ToString());
}
}
Hope you can help,
Cheers,
Vladja

Comment