Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How is strategy id assigned?

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

    How is strategy id assigned?

    How is strategy id calculated and assigned? In which case does the strategy id change? whenever the source code is compiled, the strategy is applied to the chart, reloaded, the strategy parameters are modified, underlying instrument is changed, etc.?

    #2
    Hello Clearpicks,

    Thank you for your post.

    The Strategy ID is created when the strategy is added to a chart or via Strategies tab. This is generated and stored for the database local to the PC for NinjaTrader. This allows the account performance to track orders placed via the strategy ID and see the information available for them.

    This ID does not change. It is assigned once and that is it. Once the strategy is removed or deleted, that ID is not used again but will remain in the database unless it is reset or renamed.

    Let me know if I can be of further assistance.
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Hello,
      I would like to use Strategy ID as a variable in my NinjaScript. How can it be obtained? Thank you in advance.

      Comment


        #4
        Hello InteRadek,

        You would use this.Id.

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by SalmaTrader, 07-07-2026, 10:26 PM
        0 responses
        46 views
        0 likes
        Last Post SalmaTrader  
        Started by CarlTrading, 07-05-2026, 01:16 PM
        0 responses
        22 views
        0 likes
        Last Post CarlTrading  
        Started by CaptainJack, 06-17-2026, 10:32 AM
        0 responses
        14 views
        0 likes
        Last Post CaptainJack  
        Started by kinfxhk, 06-17-2026, 04:15 AM
        0 responses
        20 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Started by kinfxhk, 06-17-2026, 04:06 AM
        0 responses
        22 views
        0 likes
        Last Post kinfxhk
        by kinfxhk
         
        Working...
        X