Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Calling a custom indicator from multiple indicators

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

    Calling a custom indicator from multiple indicators

    Hi,
    I have a custom indicator (indicator A) which calculates a number of parameters and exposes them to other indicators for use.
    Every time indicator A is accessed by another indicator a new instance of indicator A is created.
    is there a way to only create 1 instance of indicator A no matter how many indicators accessing it?​

    #2
    Hello Kevint40,

    Thank you for your post.

    Unfortunately there is no supported concept to do this in NinjaScript. Each time you call the indicator from another indicator, it will be accessing it's own instance of the indicator.

    If you wanted to share information across several indicators you could create a static class, although this is more a C# concept than it is related to NinjaScript so we don't have much documentation for this.

    Comment

    Latest Posts

    Collapse

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