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

Recursive property

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

    Recursive property

    Hallo everybody,
    I am a novice and I want to create my first strategy. But there is already the first bug.
    I hope someone can help me.
    Thank you in advance.
    Benjamin
    Attached Files

    #2
    Hello,

    Can you please post your code or send your code to support at ninjatrader dot com and reference this forum post so that we may take a quick look at it and see if we can see what is causing the issue.

    I look forward to assisting you further.

    Comment


      #3
      bascher,

      This generally means that your input variable has the same name as the public get/set method which calls it.

      For example

      Incorrect
      Code:
              private int Period1 = 5; 
              [Description("Period")]
              [Category("Parameters")]
              public int Period1
              {
                  get { return Period1; }
                  set { Period1 = value; }        	
      	}
      Correct
      Code:
              private int [B][COLOR="Red"]i[/COLOR][/B]Period1 = 5; 
              [Description("Period")]
              [Category("Parameters")]
              public int Period1
              {
                  get { return [B][COLOR="Red"]i[/COLOR][/B]Period1; }
                  set { [B][COLOR="Red"]i[/COLOR][/B]Period1 = value; }        	
      	}
      mrlogik
      NinjaTrader Ecosystem Vendor - Purelogik Trading

      Comment


        #4
        okay thank you

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by ETFVoyageur, Today, 04:00 PM
        2 responses
        14 views
        0 likes
        Last Post ETFVoyageur  
        Started by dward123, 01-02-2024, 09:59 PM
        3 responses
        166 views
        0 likes
        Last Post bjunaid
        by bjunaid
         
        Started by AaronKTradingForum, Today, 03:44 PM
        1 response
        8 views
        0 likes
        Last Post AaronKTradingForum  
        Started by Felix Reichert, 04-26-2024, 02:12 PM
        11 responses
        77 views
        0 likes
        Last Post Felix Reichert  
        Started by junkone, 04-28-2024, 02:19 PM
        7 responses
        83 views
        1 like
        Last Post junkone
        by junkone
         
        Working...
        X