Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

EnterLong() twice does not give me 2 long contracts

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

    EnterLong() twice does not give me 2 long contracts

    Hi there,

    Good day. Re the subject - I tried executing EnterLong() a few times but still ends up with one contract. Specifying a quantity does not help.(?)

    The purpose is to scale out my positions; say, adding one contract at a time. How can this be done with EnterLong(), EnterShort()?

    Thank you for your valuable input.


    Regards,
    Steven

    #2
    Hello Steven,

    What EntryHandling are you using? What is EntriesPerDirection set to?
    https://ninjatrader.com/support/help...ryhandling.htm
    https://ninjatrader.com/support/help...rdirection.htm

    Are the entries using unique signal names?

    This is discussed in the 'Automate Your Trading with NinjaTrader's Strategy Builder' training video.
    https://forum.ninjatrader.com/forum/...pts#post786040

    Below is a link to an example of scaling out.
    https://ninjatrader.com/support/foru...80#post1077380

    Have you enabled TraceOrders to see if the order is being ignored?
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Hi Chelsea,

      EntriesPerDirection = 5;
      EntryHandling = EntryHandling.AllEntries;

      Typo. I intended to say 'scale in' - that's the problem I encountered. I could not add positions. Do I have to use signal name in order to add positions wz EnterLong() or EnterShort()? I did not use it in my previous tests.

      Regards,
      Steven

      Comment


        #4
        Hello Steven,

        When using EntriesPerDirection I would expect up to 5 entry orders to be submitted.
        This wasn't changed, correct? (If it was changed in State.SetDefaults, you will need to remove the strategy instance and add a new instance to pull the new defaults)

        May I have the output from the NinjaScript Output window with the TraceOrders information to see if the orders are being ignored?
        Chelsea B.NinjaTrader Customer Service

        Comment


          #5
          hi Chelsea,

          Ok. I'll send to you the info when I get to test the new version of my strategy again.

          Regards,
          Steven

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by NullPointStrategies, Today, 05:17 AM
          0 responses
          50 views
          0 likes
          Last Post NullPointStrategies  
          Started by argusthome, 03-08-2026, 10:06 AM
          0 responses
          126 views
          0 likes
          Last Post argusthome  
          Started by NabilKhattabi, 03-06-2026, 11:18 AM
          0 responses
          69 views
          0 likes
          Last Post NabilKhattabi  
          Started by Deep42, 03-06-2026, 12:28 AM
          0 responses
          42 views
          0 likes
          Last Post Deep42
          by Deep42
           
          Started by TheRealMorford, 03-05-2026, 06:15 PM
          0 responses
          46 views
          0 likes
          Last Post TheRealMorford  
          Working...
          X