Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Automated Strategy... need help in OCO orders

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Automated Strategy... need help in OCO orders

    I have had some communication problems lately... and I have been dropping out right after my strategy places a manual buy order... So, I am stuck and can't get the sell order to the broker in time... Thus, I thought that an OCO order might just be the right thing... So the way it works is the "OCO" value must be the same... and the order of submission determines how it works... buy first then sell..

    SubmitOrder(0, OrderAction.Buy, OrderType.Limit, 100, 10.00, 0, "Tiedtogether", "Manual");

    SubmitOrder(0, OrderAction.Sell, OrderType.Limit, 100, 10.10, 0, "Tiedtogether", "Manual");

    So in my example above... I submit a buy order and I tie it with "Tiedtogether" and the broker will then know the next order will be based on the buy order completing...

    Is my thought process right so far?... What happens if the buy order doesn't fill all the way... It's all or none.... right?

    Thank you for your response .... I await your answers.

    #2
    theotterway, your though process is correct - if partial fills come in for one leg of the bracket this would be reflected in the other part so you would see PendingChange requests as the qty of the order is amended to reflect to received executions. Once the complete Filled state is seen, the other OCO order is cancelled then.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    77 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    45 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    27 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    32 views
    0 likes
    Last Post TheRealMorford  
    Started by Mindset, 02-28-2026, 06:16 AM
    0 responses
    63 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Working...
    X