Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Limitat of the number of entries.

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

    Limitat of the number of entries.

    Hello. Can I set the limit of the number of particular EntryOrder can be executed, and prevent any further executions once the limit has been reached?

    #2
    Hello Czarek,

    Thank you for your post.

    Are you referring to the number of entries at one time? If so, the strategy properties allow you to set EntriesPerDirection which is based on the EntryHandling property. The default value for these properties may be set in State.SetDefaults and the values may be adjusted on the UI when setting up the strategy:Otherwise, if you mean overall you only want an entry to be executed X number of times in a strategy, then that entry will no longer be executed, you could set up an int in your strategy that increments each time the EntryOrder is executed. You could also have a bool that is set to true when the EntryOrder is allowed, and once that int reaches the desired count, the bool could then be set to false so the entry logic will no longer be executed.

    Please let us know if we may be of further assistance.

    Comment


      #3
      Hi. Thanks for your reply.
      I mean I only want an entry to be executed X number of times in a strategy, then that entry will no longer be executed.
      How to set up an int in my strategy that increments each time the EntryOrder is executed?

      Comment


        #4
        Hello Czarek,

        You would need to accomplish this with logic.

        For example you can increment an integer as a counter, and require the integer value to be less than a specific number in the condition that submits the entry.

        Below is a link to a forum post that discusses.
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by NullPointStrategies, Yesterday, 05:17 AM
        0 responses
        81 views
        0 likes
        Last Post NullPointStrategies  
        Started by argusthome, 03-08-2026, 10:06 AM
        0 responses
        149 views
        0 likes
        Last Post argusthome  
        Started by NabilKhattabi, 03-06-2026, 11:18 AM
        0 responses
        79 views
        0 likes
        Last Post NabilKhattabi  
        Started by Deep42, 03-06-2026, 12:28 AM
        0 responses
        52 views
        0 likes
        Last Post Deep42
        by Deep42
         
        Started by TheRealMorford, 03-05-2026, 06:15 PM
        0 responses
        58 views
        0 likes
        Last Post TheRealMorford  
        Working...
        X