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 > General Programming

General Programming General NinjaScript programming questions.

Reply
 
Thread Tools Display Modes
Old 12-07-2010, 12:33 PM   #1
occam
Member
 
Join Date: Aug 2010
Posts: 89
Thanks: 0
Thanked 0 times in 0 posts
Send a message via Skype™ to occam
Default Order Cancelling

With CalculateOnBarClose = false
Place an order, EnterLongStop and indicate you want it to cancel at the end of the bar

If this event occurs will it appear in OnExecution() as

execution.Order.OrderState == OrderState.Cancelled ?
occam is offline  
Reply With Quote
Old 12-07-2010, 12:46 PM   #2
NinjaTrader_Brett
NinjaTrader Customer Service
 
NinjaTrader_Brett's Avatar
 
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,498
Thanks: 109
Thanked 291 times in 280 posts
Default

Hello,

This should occur on the iOrder, are you seeing something different?

I look forward to assisting you further.
NinjaTrader_Brett is offline  
Reply With Quote
Old 12-08-2010, 07:10 AM   #3
occam
Member
 
Join Date: Aug 2010
Posts: 89
Thanks: 0
Thanked 0 times in 0 posts
Send a message via Skype™ to occam
Default

No I think it is ok. Just checking.

Another question, a partial fill that completes the order would appear as
OrderState.Filled correct?
occam is offline  
Reply With Quote
Old 12-08-2010, 07:17 AM   #4
NinjaTrader_Brett
NinjaTrader Customer Service
 
NinjaTrader_Brett's Avatar
 
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,498
Thanks: 109
Thanked 291 times in 280 posts
Default

Hello,

Yes it would change to a Filled order state.

Let me know if I can be of further assistance.
NinjaTrader_Brett is offline  
Reply With Quote
Old 12-08-2010, 08:16 AM   #5
occam
Member
 
Join Date: Aug 2010
Posts: 89
Thanks: 0
Thanked 0 times in 0 posts
Send a message via Skype™ to occam
Default

In say a ExitLongStop() what is liveUntilCancelled default?

If false and assume not triggered the order expires when? Just before the next OnBarUpdate() is called assuming only one bar is in use?
occam is offline  
Reply With Quote
Old 12-08-2010, 08:30 AM   #6
NinjaTrader_Brett
NinjaTrader Customer Service
 
NinjaTrader_Brett's Avatar
 
Join Date: Dec 2009
Location: Denver, CO, USA
Posts: 6,498
Thanks: 109
Thanked 291 times in 280 posts
Default

Hello,

By Default you must resubmit this order on every OnBarUpdate or else it will be cancelled.

Let me know if I can be of further assistance.
NinjaTrader_Brett 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
Order not cancelling zark.be Automated Trading 3 07-13-2010 06:00 AM
Cancelling a Pending Order. jonmoron General Programming 5 07-26-2009 11:39 AM
Cancelling open order(s). 8DTK8 Strategy Development 5 09-29-2008 12:04 PM
Cancelling and automated order thepcmd Automated Trading 4 04-23-2008 09:33 PM
Automatic Order cancelling khawaja Automated Trading 3 10-17-2007 02:24 PM


All times are GMT -6. The time now is 09:43 AM.