Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Order Entry Error

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

    Order Entry Error

    I keep getting the following error message:
    "An order has been ignored since the stop price ‘2010.25’ near the bar stamped ‘1/13/2015 12:20:00 PM’ is invalid based on the price range of the bar. This is an invalid order and subsequent orders may also be ignored."

    This is coming from "SubmitOrderUnmanaged()", Sell, StopMarket on the 1 tick series; the primary series is the ES 1 minute. eg, my StopMarket price is 2010.25, and the Lows[0][0] = 2010.75, so this should work, right (ie, that the StopMarket price is below the low of the most recent bar; I've also tried Lows[1][0], but get the same error)?


    #2
    Hi, thanks for posting. The stop price is invalid, likely in historical data. Since its a Sell Stop order the price used needs to be below the open of the bar. Try using this variable as your stop price:
    Code:
    double stopPrice = Math.Min(Lows[1][0], GetCurrentBid() - TickSize);

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by CarlTrading, 05-11-2026, 05:56 AM
    0 responses
    61 views
    0 likes
    Last Post CarlTrading  
    Started by CarlTrading, 05-10-2026, 08:12 PM
    0 responses
    34 views
    0 likes
    Last Post CarlTrading  
    Started by Hwop38, 05-04-2026, 07:02 PM
    0 responses
    198 views
    0 likes
    Last Post Hwop38
    by Hwop38
     
    Started by CaptainJack, 04-24-2026, 11:07 PM
    0 responses
    364 views
    0 likes
    Last Post CaptainJack  
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    283 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Working...
    X