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

NinjaScript generated code not updated if comments are added

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

    NinjaScript generated code not updated if comments are added

    hi

    I noticed that the NinjaScript generated code is not updated when you add a new parameter to your indicator and put a comment after the definition and before the get/set line.
    The below example will not update the NinjaScript generated code upon saving. The indicator will still run perfectly fine until you reference it from a strategy or another indicator.
    Then you have a mismatch in the # of parameters and it took me quite some time to figure out what was going on.
    You may want to address this in code or mention in the documentation.

    [NinjaScriptProperty]
    [Display(Name = "Period", Order = 10, GroupName = "Parameters")]
    public int Period // some comment put here
    { get; set; }



    #2
    Hello DukuGrinder,

    Thank you for reporting this.

    I was able to reproduce.

    I will submit a feature request to allow for comments after NinjaScriptProperty public object declarations.

    I will also request this be mentioned in the help guide.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      it is not a feature request, it is a bug..

      Comment


        #4
        Hello DukuGrinder,

        NinjaTrader has a NinjaScript wrapper that parses the indicator file before compiling to create the NinjaScript generated code. This wrapper comes with limitations like we see here. We will be making some documentation updates in the future to outline these limitations.

        If there is any other behavior that you are seeing with the NinjaScript Generated code that you would like to report so we can have it documented, we will be happy to review.
        JimNinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by bmartz, 03-12-2024, 06:12 AM
        5 responses
        32 views
        0 likes
        Last Post NinjaTrader_Zachary  
        Started by Aviram Y, Today, 05:29 AM
        4 responses
        12 views
        0 likes
        Last Post Aviram Y  
        Started by algospoke, 04-17-2024, 06:40 PM
        3 responses
        28 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by gentlebenthebear, Today, 01:30 AM
        1 response
        8 views
        0 likes
        Last Post NinjaTrader_Jesse  
        Started by cls71, Today, 04:45 AM
        1 response
        7 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Working...
        X