Hello folks,
I know this must be a dumb question, but I don't know how to approach the solution yet.
I want to place 3 pending orders, all 20 pips apart. I don't want to have the OrderOpen code three times. I know there is a better way, I guess it's called a loop
Now how do I get this to run three times and basically add 20 pips to the
PipsApart variable?
Thank you.
MikeFT
I know this must be a dumb question, but I don't know how to approach the solution yet.
I want to place 3 pending orders, all 20 pips apart. I don't want to have the OrderOpen code three times. I know there is a better way, I guess it's called a loop
Inserted Code
PipsApart = 0; //this value needs to be + 20 for each additional order Currentbit = Bit + PipsApart; PriceBuyStop = Currentbid + PipsApart; SLBuyStop = Currentbid-(StopLoss*Point*FourFiveDigitBrokerCalc); TPBuyStop = Currentbid+(TakeProfit*Point*FourFiveDigitBrokerCalc); OrderSendReliable(Symbol(),OP_BUYSTOP,Lots,PriceBuyStop,3,SLBuyStop,TPBuyStop,"BBT-PendSellStop",0,expiration,CLR_NONE);
PipsApart variable?
Thank you.
MikeFT