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

Problem Calling Indicator

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

    Problem Calling Indicator

    Hi, im trying to call an indicator from a strategy, ive called a few already with no biggie, but this one just doesn't let me and i cant figure out why.

    its just Bollinger Bandwidth i modified with some extra options .. the thing is im only getting 2 options, bar type and period , the rest, like bollinger period , deviation , etc just doesn't show up, ive tried entering the rest by "force" and guessing, of course with no luck. What am i missing? Thank you!


    Click image for larger version

Name:	2015-10-22_224731.jpg
Views:	1
Size:	13.8 KB
ID:	904164
    KBT_BBW_V1.cs
    Last edited by kabott; 10-23-2015, 07:37 AM.

    #2
    Hello,
    Can you verify what options you receive if you select the second overload for the indicator?
    You can check the second overload by pressing the down arrow key when viewing the overload methods.

    Could you attach the indicator as well so I may investigate it further?
    You can attach your indicator to your response by going to File > Utilities > Export NinjaScript > Export selected source files > select your Indicator > select the right arrow > Export. The file will be located under (My) Documents\NinjaTrader 7\bin\Custom\ExportNinjaScript.

    I look forward to your reply.
    Cody B.NinjaTrader Customer Service

    Comment


      #3
      Hi Cody, the second overload has the same 2 inputs as the first, the indicator is attached already below the image in my original post its called "KBT_BBW_V1"

      thanks for your help cody

      I copy the .cs directly cause im getting error when exporting "the name Bollinger does not exists in the current context"

      may it be related to my issue?
      Last edited by kabott; 10-23-2015, 10:01 AM.

      Comment


        #4
        Hello,
        The reason only two constructors are is because only two constructors are defined in the code. The two that you are seeing are in the NinjaScript Generated code.
        To resolve this you would need to define additional constructors. You would want to define the constructors outside of the NinjaScript Generated code though.

        Please see the following link on creating constructors with C#.https://msdn.microsoft.com/en-us/library/ms173115.aspx

        Please let me know if they do not appear after you have defined the constructors.
        Cody B.NinjaTrader Customer Service

        Comment


          #5
          Hi Cody, but why? i dont understand why Ninja would define only two constructors, i mean what part of the script is causing this problem?
          Why is Ninja doing this? i mean it has happen just this time and ive done and modified a zillion other indicators..

          Comment


            #6
            Originally posted by kabott View Post
            Hi Cody, but why? i dont understand why Ninja would define only two constructors, i mean what part of the script is causing this problem?
            Why is Ninja doing this? i mean it has happen just this time and ive done and modified a zillion other indicators..
            Have you correctly defined your additions as Properties, with the correct Attribute decorators?

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by bortz, 11-06-2023, 08:04 AM
            47 responses
            1,603 views
            0 likes
            Last Post aligator  
            Started by jaybedreamin, Today, 05:56 PM
            0 responses
            8 views
            0 likes
            Last Post jaybedreamin  
            Started by DJ888, 04-16-2024, 06:09 PM
            6 responses
            18 views
            0 likes
            Last Post DJ888
            by DJ888
             
            Started by Jon17, Today, 04:33 PM
            0 responses
            4 views
            0 likes
            Last Post Jon17
            by Jon17
             
            Started by Javierw.ok, Today, 04:12 PM
            0 responses
            12 views
            0 likes
            Last Post Javierw.ok  
            Working...
            X