Author |
Topic: market order (3 messages, Page 1 of 1) |
||||
---|---|---|---|---|---|
Moderators: VPfau | |||||
MRalston6576 Posts: 1 Joined: Feb 27, 2017 |
I want to be able to place market orders with an fx account where there will be a stop and a limit (the limit may or may not be specified depending on the circumstance). I tried various ways of doing this with the sendocoorders but nothing is accepted.
Can you provide a quick overview of what the code looks like to implement a market order with a stop and a limit? |
||||
CMicciche902 Posts: 367 Joined: |
I do not send related orders, just unlinked market order. Review https://gainfutures.com/api/html/9900566b-260a-4247-8326-9698b013e7b8.htm and scroll down to section
One-Send-Others and One-Cancel-Other Placing of OSO (or bracket orders) requires only to replace a method SendOrder(OrderDraft) to SendLinkedOrders(OrderDraft,OrderDraft[] ) for OSO and to SendOCOOrders(OrderDraft[]). All other functionality remains the same. OCO and OSO orders have links to each others: Parent for reference from a dependent order to the main one Linked for reference from the main OSO order to dependent ones OCO for reference from one OCO order to another Chris M
|
||||
CMicciche902 Posts: 367 Joined: |
We have sample code on Bitbucket https://bitbucket.org/GainFuturesDev/advancedexample/src/2f828076ce7bd06a3b0737eb8d243384af3b745f/OrdersOCOControl.cs?at=master&fileviewer=file-view-default or downloaded from https://gainfutures.com/onelink/documentation#tab-2
Chris M
|
||||