Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Long trades with bid prices

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

    Long trades with bid prices

    Hi,

    I run my first strategy in live simulation mode using MB trading data.

    I have indicated that short trades are opened with bid prices and long trades with ask prices.

    Is it possible to open long trades with bid prices also? How can it be done?

    Please support.

    #2
    Hello kucharek,

    Unfortunately this is not supported. Buy orders will execute at the ask price and sell orders execute at the bid price.

    Comment


      #3
      Thanks. Do you plan to add this feature? If yes, when could it be available?

      Comment


        #4
        NinjaTrader does not have any control on the execution of orders. Orders execute at the exchange as per market dynamics. As far as I know it is not possible to have a buy order execute at the bid price.

        Comment


          #5
          Maybe, we misunderstood. I know that I my buy order will execute at the ask price.

          My entry buy stop order is "High[0] + 1 * TickSize". I want to open a trade when bid price reaches this level, not the ask price.

          I want to open long position (at ask price) when bid price (not ask) reaches stop order.

          Comment


            #6
            kucharek, it will depend upon your code when the order is submitted and at which price - as long as the submitted stop order continues to be a valid order (stop price higher >= Ask for a buy), otherwise it would be rejected.

            Comment


              #7
              Yes, I know that it shall be in my code.

              Please support what method shall I use in order to open long position when when BID price reaches certain level.

              Comment


                #8
                You can monitor the current bid in realtime with GetCurrentBid().

                Your resulting stop order could be placed then at a price value of GetCurrentAsk(), but depending on market dynamics you could hit rejected orders with this approach.

                Comment


                  #9
                  Originally posted by kucharek View Post
                  Maybe, we misunderstood. I know that I my buy order will execute at the ask price.

                  My entry buy stop order is "High[0] + 1 * TickSize". I want to open a trade when bid price reaches this level, not the ask price.

                  I want to open long position (at ask price) when bid price (not ask) reaches stop order.
                  You will have to submit your orders as limit orders at the bid in that case. You can get the bid price by more than one means.

                  There is GetCurrentBid() for use in the OnBarUpdate() event, and MarketDataType matching in the OnMarketData() or OnMarketDepth() events. Search the help using those terms.

                  Comment

                  Latest Posts

                  Collapse

                  Topics Statistics Last Post
                  Started by argusthome, 03-08-2026, 10:06 AM
                  0 responses
                  110 views
                  0 likes
                  Last Post argusthome  
                  Started by NabilKhattabi, 03-06-2026, 11:18 AM
                  0 responses
                  59 views
                  0 likes
                  Last Post NabilKhattabi  
                  Started by Deep42, 03-06-2026, 12:28 AM
                  0 responses
                  37 views
                  0 likes
                  Last Post Deep42
                  by Deep42
                   
                  Started by TheRealMorford, 03-05-2026, 06:15 PM
                  0 responses
                  41 views
                  0 likes
                  Last Post TheRealMorford  
                  Started by Mindset, 02-28-2026, 06:16 AM
                  0 responses
                  78 views
                  0 likes
                  Last Post Mindset
                  by Mindset
                   
                  Working...
                  X