{"id":8173,"date":"2025-09-04T23:20:34","date_gmt":"2025-09-05T04:20:34","guid":{"rendered":"https:\/\/librarytestdev.wpenginepowered.com\/?post_type=doc&#038;p=8173"},"modified":"2025-09-04T23:23:44","modified_gmt":"2025-09-05T04:23:44","slug":"manage-staged-orders","status":"publish","type":"doc","link":"https:\/\/library-staging.tradingtechnologies.com\/apis\/tt-net-sdk\/advanced-concepts-and-options\/manage-staged-orders\/","title":{"rendered":"Manage Staged Orders"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\" id=\"overview\">Overview<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">TT .NET Client Side now supports adding, changing, and deleting Staged Orders.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For an overview of Staged Orders, refer to the&nbsp;<a href=\"\/trade\/co-staged-orders-overview.html\">Care Orders Overview<\/a>&nbsp;section of the Setup help.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"submitting-a-new-staged-order\"><a href=\"\/tt-net-sdk\/articles\/ac-staged-orders.html#submitting-a-new-staged-order\"><\/a>Submitting a new Staged Order<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">To submit a new Staged Order, you must first create an&nbsp;<a href=\"\/tt-net-sdk\/api\/tt_net_sdk.OrderProfile.html\">OrderProfile<\/a>&nbsp;object using the&nbsp;<strong>isStagedOrder<\/strong>&nbsp;Flag set to&nbsp;<em>true<\/em>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">The new fields that can be set on the Profile are:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>StagedOrderMessage<\/strong>\u00a0(String)<\/li>\n\n\n\n<li><strong>BestMarketPrice<\/strong>\u00a0(Price)<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">For example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>void submitOrder(Instrument inst, Account acct, Price p)\n{\n  OrderProfile op = new OrderProfile(inst, true);\n  op.BuySell = BuySell.Buy;\n  op.Account = acct;\n  op.OrderQuantity = Quantity.FromDecimal(inst, 10);\n  op.OrderType = OrderType.Limit;\n  op.LimitPrice = p;\n  op.StagedOrderMessage = \u201cMy Staged order\u201d;\n  op.BestMarketPrice = 100.00;\n\n  if (!m_ts.SendOrder(op))\n  {\n    Console.WriteLine(\"Send new order Failed.\");\n  }\n  else\n  {\n    Console.WriteLine(\"Sent new order: \" + \" SOK=\" +    op.SiteOrderKey);\n  }\n}\n<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"modifying-and-deleting-a-staged-order\"><a href=\"\/tt-net-sdk\/articles\/ac-staged-orders.html#modifying-and-deleting-a-staged-order\"><\/a>Modifying and Deleting a Staged Order<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Staged orders can be modified and deleted the same way as regular orders. After making the desired changes, set the value of the&nbsp;<a href=\"\/tt-net-sdk\/api\/tt_net_sdk.OrderProfile.html#tt_net_sdk_OrderProfile_Action\">OrderProfile.Action<\/a>&nbsp;property to indicate how the existing order should be modified, as follows:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>To delete the existing order, set the value to\u00a0<a href=\"\/tt-net-sdk\/api\/tt_net_sdk.OrderProfile.html#tt_net_sdk_OrderProfile_Action\">OrderAction.Delete<\/a>.<\/li>\n\n\n\n<li>To place the existing order on hold, set the value to\u00a0<a href=\"\/tt-net-sdk\/api\/tt_net_sdk.OrderProfile.html#tt_net_sdk_OrderProfile_Action\">OrderAction.Hold<\/a>\u00a0to resubmit a held order, set the value to\u00a0<a href=\"\/tt-net-sdk\/api\/tt_net_sdk.OrderProfile.html#tt_net_sdk_OrderProfile_Action\">OrderAction.Resubmit<\/a>.<\/li>\n\n\n\n<li>To modify the existing order values, set the value to\u00a0<a href=\"\/tt-net-sdk\/api\/tt_net_sdk.OrderProfile.html#tt_net_sdk_OrderProfile_Action\">OrderAction.Change<\/a>.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">For example:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>void changeOrderPrice(string key, Price p)\n{\n  if (m_ts.Orders.ContainsKey(key))\n  {\n    Order order = m_ts.Orders&#91;key];\n    OrderProfile op  = order.GetOrderProfile();\n    op.LimitPrice = p;\n    op.Action = OrderAction.Change;\ngit\n    if (!m_ts.SendOrder(op))\n    {\n      Console.WriteLine(\"Send change order Failed.\");\n    }\n    else\n    {\n      Console.WriteLine(\"Sent order change request.\");\n    }\n  }\n}<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Overview TT .NET Client Side now supports adding, changing, and deleting Staged Orders. For an overview of Sta [&hellip;]<\/p>\n","protected":false},"author":2,"template":"wp-custom-template-single-doc-tt-net-sdk","meta":{"_acf_changed":true,"footnotes":""},"docs-category":[776],"class_list":["post-8173","doc","type-doc","status-publish","hentry","docs-category-advanced-concepts-and-options"],"acf":[],"_links":{"self":[{"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/doc\/8173","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/doc"}],"about":[{"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/types\/doc"}],"author":[{"embeddable":true,"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/users\/2"}],"version-history":[{"count":0,"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/doc\/8173\/revisions"}],"wp:attachment":[{"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/media?parent=8173"}],"wp:term":[{"taxonomy":"docs-category","embeddable":true,"href":"https:\/\/library-staging.tradingtechnologies.com\/ja\/wp-json\/wp\/v2\/docs-category?post=8173"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}