Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Order Type

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

    Order Type

    I'm not clear on how to set the order types for unmanaged orders.

    1. If I want to buy at the market I'll submit an order with the orderaction.buy and ordertype.market. What do I need for simple stop and limit orders for fixed prices?

    2. If I want to sell at the market I'll submit an order with the orderaction.see and ordertype.market. What do I need for simple stop and limit orders for fixed prices?

    Thanks!!

    #2
    Hello
    Thanks for your post.

    For a limit or stopLimit you will specify the OrderType as OrderType.Limit or OrderType.StopLimit

    You would then need to add the limit price or the limit price and the stop price depending on the order type of limit or stoplimit. The helpguide shows the variation to include the limit price and stop limit price.

    Please see the helpguide here on SubmitOrderUnmanaged(): http://ninjatrader.com/support/helpG...runmanaged.htm

    Limit example:

    SubmitOrderUnmanaged(0, OrderAction.Buy, OrderType.Limit, 1, 2475.25, 0, "", "Enter Long"); In this example it is a buy limit with a price of 2475.25. A quantity of 1. As this is not a stop limit a 0 (zero) is entered for the stop price. As there is no OCO associated the OCO string is empty "". The signal name is "EnterLong". This example matches the last signature shown for the method in the helpguide. SubmitOrderUnmanaged(int selectedBarsInProgress, OrderAction orderAction, OrderType orderType, int quantity, double limitPrice, double stopPrice, string oco, string signalName)

    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
    119 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