开云体育No it isn't possible, that's why I suggested what I did. If I had thought it were possible, I'd have said so: it was obvious from your question that that was what you were hoping for. ? When you create a bracket order, you can attach any number of child orders to the parent, and the child orders all become an OCA group, with an IB-generated OCA group identifier: for example you could add a both a limit profit taker and also a MOC profit taker, the latter only being relevant if the limit price is not reached during the session. When any one of the child orders is eventually filled, all the others are cancelled, precisely because they are an OCA group. But you already know this because that's exactly what you found… ? It would be nice if IB could extend this mechanism to allow multiple child OCA groups (for example by allowing the API client to specifically set the OCA group identifier differently for different child order groups), but I suspect this would considerably complicate IB's logic and there may be tricky edge cases. Also I doubt it would actually be much used. ? Richard ? ? From: [email protected] <[email protected]> On Behalf Of Pavan M
Sent: 04 February 2021 08:05 To: [email protected] Subject: Re: [TWS API] Place a Limit Order with 2 Profit Takers and 1 Stop Loss for a Stock ? Thank You for your response Richard. ? Actually I should have been a little more specific.? Is it possible to pack them into 1 order. Meaning - IB treats a Bracket Order (Limit Order with 1 Profit Taker and 1 Stop Loss) as 1 order (although internally we are placing 3 orders when using the API and handling transmit settings). Similarly can I create a package such that "Limit Order with 2 Profit Takers and 1 Stop Loss" is also treated as 1 order.? ? Thank You. -- |