NinjaTrader Support Forum  
X

Attention!

This website will be down for maintenance from Friday May 24th at 6PM MDT until Saturday May 25th at 11AM MDT. We apologize for the inconvenience. If you need assistance during this time, please email sales@ninjatrader.com


Go Back   NinjaTrader Support Forum > NinjaScript Development Support > Strategy Development

Strategy Development Support for the development of custom automated trading strategies using NinjaScript.

Reply
 
Thread Tools Display Modes
Old 07-15-2008, 12:20 PM   #1
stefy
Senior Member
 
Join Date: Apr 2008
Posts: 310
Thanks: 0
Thanked 0 times in 0 posts
Default OCO orders

I generate once a day two threshold values and I want to generate just two orders (OCO) for those values.
How can I do that?

Thank you
stefy is offline  
Reply With Quote
Old 07-15-2008, 02:02 PM   #2
NinjaTrader_Ray
Administrator
 
NinjaTrader_Ray's Avatar
 
Join Date: Nov 2004
Location: Denver, CO, USA
Posts: 11,163
Thanks: 6
Thanked 45 times in 32 posts
Default

Currently in single instance of a NinjaScript strategy you can't place two OCO entry orders. You would need to run two separate strategies, each one representing a different order.
NinjaTrader_Ray is offline  
Reply With Quote
Old 07-15-2008, 02:14 PM   #3
stefy
Senior Member
 
Join Date: Apr 2008
Posts: 310
Thanks: 0
Thanked 0 times in 0 posts
Default

OK, but how can I place an OCO order?

Thank you
stefy is offline  
Reply With Quote
Old 07-15-2008, 02:37 PM   #4
NinjaTrader_Ray
Administrator
 
NinjaTrader_Ray's Avatar
 
Join Date: Nov 2004
Location: Denver, CO, USA
Posts: 11,163
Thanks: 6
Thanked 45 times in 32 posts
Default

You can't.
NinjaTrader_Ray is offline  
Reply With Quote
Old 02-28-2010, 01:40 PM   #5
jonmoron
Senior Member
 
Join Date: Jan 2009
Posts: 124
Thanks: 0
Thanked 1 time in 1 post
Default

Is this still the case with NT 6.5 or NT7?
I'd like to place two orders as an entry. If one gets filled, I want the other to be canceled. Sometimes these others will be LIMIT orders other times they might be STOP. In any case both orders will be of the same type. However I'm looking to place 1 set of two orders and I want the unfilled order to be cancelled when one of the two is filled. Is there anything available for this in a strategy?

thanks!



Quote:
Originally Posted by NinjaTrader_Ray View Post
You can't.
jonmoron is offline  
Reply With Quote
Old 02-28-2010, 08:57 PM   #6
NinjaTrader_Ben
NinjaTrader Customer Service
 
NinjaTrader_Ben's Avatar
 
Join Date: May 2008
Location: Denver, CO
Posts: 3,157
Thanks: 0
Thanked 3 times in 3 posts
Default

Hello,

I will have someone reply to you on Monday. Thank you for your patience.
NinjaTrader_Ben is offline  
Reply With Quote
Old 03-01-2010, 03:53 AM   #7
NinjaTrader_Bertrand
NinjaTrader Customer Service
 
NinjaTrader_Bertrand's Avatar
 
Join Date: Sep 2008
Location: Germany
Posts: 22,414
Thanks: 252
Thanked 977 times in 960 posts
Default

jonmoron, the same internal order rules would exist in NT7, meaning you can't place this entry limit / stop bracket in advance with auto OCO'ing the not needed one...however we have a new unmanaged order submission feature where such scenarios could be realized without the internal order handling rules stepping in...

http://www.ninjatrader.com/webnew/NT7/NinjaTrader7.html

New Unmanaged Order Submission
In 6.5 some users were burdened with our "Internal Order Handling" rules. We have introduced unmanaged order submission which bypasses the convenience of our order handling layer. This lower level of programming allows you to do what you want relative to order submission/management without any limitations other than any imposed by your broker. There are only three methods, SubmitOrder(), ChangeOrder() and CancelOrder(). You then get the flexibility of managing your orders how you see fit and optionally handling rejections.
NinjaTrader_Bertrand is offline  
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Limit orders - book position kept when new orders are generated Fabrice Automated Trading 6 10-13-2007 03:16 PM
Targets - Stop Orders or Stop Limit Orders? Nereus ATM Strategies (Discretionary Trading) 3 05-31-2005 07:13 AM
Why does cancel all orders in NT Light cancel real orders in TWS dwight Miscellaneous Support 0 11-29-2004 01:54 PM


All times are GMT -6. The time now is 12:24 PM.