I am re-writing my strategies for the forthcoming beta that supports limit orders.
Will the following send a LIMIT order to Interactivebrokers at the price of the close of the bar that met the condition:
If condition1 = true then BuyPoint = Close;
Buy 5 contracts next bar at BuyPoint Limit;
Limit Order Syntax
- Marina Pashkova
- Posts: 2758
- Joined: 27 Jul 2007
- Marina Pashkova
- Posts: 2758
- Joined: 27 Jul 2007
Hi momentum,
As it is, only the second line of the code you posted will generate a limit order. This limit order will be generated on the next bar at a price of BuyPoint or lower.
If condition1 is met, it will simpy result in assigning the value equalling Close to the BuyPoint. This line of code does not affect generation of the order.
Regards.
As it is, only the second line of the code you posted will generate a limit order. This limit order will be generated on the next bar at a price of BuyPoint or lower.
If condition1 is met, it will simpy result in assigning the value equalling Close to the BuyPoint. This line of code does not affect generation of the order.
Regards.