Announcement

Collapse

Looking for a User App or Add-On built by the NinjaTrader community?

Visit NinjaTrader EcoSystem and our free User App Share!

Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less

Partner 728x90

Collapse

Need to know a class that both indicator and Strategy inherit from

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

    Need to know a class that both indicator and Strategy inherit from

    Good afternoon, I have a class that collects indicator type of information. I want to set it up so that it collects the same information in both indicator and strategy classes( for different purposes). Is there a shared Interface or class that both indicator and strategy share/ inherit from?

    #2
    Hello Yandychang,

    Thank you for your post.

    I would first like to clarify since you have posted in the NinjaTrader 7 section of the forum; are you looking for this information for developing in NinjaTrader 7 or in NinjaTrader 8? There is some basic information pertaining to both versions and how they are different from each other on the Code Breaking Changes page under the header "Partial Classes (Porting methods and properties from UserDefinedMethods.cs)"


    I look forward to your clarification.
    Emily C.NinjaTrader Customer Service

    Comment


      #3
      Post was meant for Ninjatrader 8.

      Comment


        #4
        Hello Yandychang,

        Thank you for your reply.

        I have moved the topic to the NinjaTrader Desktop > General Development section accordingly. My colleague has created an example of using a static property that shares information between indicator and strategy instances that may be found in the following post:


        In NinjaTrader 8, both indicators and strategies are part of the NinjaTrader.NinjaScript namespace. Adding a method to that namespace would be difficult and is not documented nor supported, so what Chelsea does in that example is used the fully qualified namespace.

        Please let us know if we may be of further assistance.
        Emily C.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by rhyminkevin, Today, 04:58 PM
        3 responses
        47 views
        0 likes
        Last Post Anfedport  
        Started by iceman2018, Today, 05:07 PM
        0 responses
        5 views
        0 likes
        Last Post iceman2018  
        Started by lightsun47, Today, 03:51 PM
        0 responses
        7 views
        0 likes
        Last Post lightsun47  
        Started by 00nevest, Today, 02:27 PM
        1 response
        14 views
        0 likes
        Last Post 00nevest  
        Started by futtrader, 04-21-2024, 01:50 AM
        4 responses
        50 views
        0 likes
        Last Post futtrader  
        Working...
        X