Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Unmanaged Limit Short Order

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

    Unmanaged Limit Short Order

    What am I missing?

    My unmanaged Limit Short order is getting filled at market.
    All my print statements state there should be a limit short order placed at 21730 (the price where 10SMA/20SMA crossed). The order is filled on the bar after the cross at MARKET (21689.50).

    Here's my code:
    Code:
                        if (limitOrder == true) {
                            Print(Times[0][0] + "  ------------- Entering a Limit Order at: " + shortLimit);
                            SubmitOrderUnmanaged(0, OrderAction.SellShort, OrderType.Limit, Qty, 0, shortLimit, oco, "Short entry");
                            limitOrder = false;
                        } else {
                            SubmitOrderUnmanaged(0, OrderAction.SellShort, OrderType.StopMarket, Qty, 0, mktShortStop, oco, "Short entry");
                        }
    
    ​
    See attached screenshots
    Attached Files

    #2
    Never mind, I need to place a zero for the market-price.

    SubmitOrderUnmanaged(0, OrderAction.SellShort, OrderType.Limit, Qty, shortLimit, 0, oco, "Short entry");

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    88 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    134 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    68 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by cmoran13, 04-16-2026, 01:02 PM
    0 responses
    118 views
    0 likes
    Last Post cmoran13  
    Started by PaulMohn, 04-10-2026, 11:11 AM
    0 responses
    67 views
    0 likes
    Last Post PaulMohn  
    Working...
    X