• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Ninjascript to detect the same stratetgy running at the same time

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

    Ninjascript to detect the same stratetgy running at the same time

    If I have a strategy called "StratA", I can enable multiple instances of this strategy in the "Strategies" tab. Is there a way in NinjaScritp to check for multiple instances of "StratA" is enabled and running? If so, is there a way to prevent multiple instances from running?

    #2
    Hello hotsalami,

    Not with any supported methods..

    Each instance is separate and not designed to communicate.

    So, this would require static classes / properties and would be custom programming. If your static bool is true, one of the scripts is on. If that script turns off, then set the bool back to false.

    Below is a link to a forum post of an unsupported example with the code you need.
    https://ninjatrader.com/support/foru...245#post712245
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by RandanAL, Today, 09:05 AM
    0 responses
    2 views
    0 likes
    Last Post RandanAL  
    Started by cstern71, 09-02-2019, 10:30 AM
    4 responses
    59 views
    0 likes
    Last Post Lancer
    by Lancer
     
    Started by Hanstanz, Today, 04:44 AM
    0 responses
    10 views
    0 likes
    Last Post Hanstanz  
    Started by juniortut, Today, 04:38 AM
    0 responses
    5 views
    0 likes
    Last Post juniortut  
    Started by rojiinko, Today, 03:58 AM
    0 responses
    5 views
    0 likes
    Last Post rojiinko  
    Working...
    X