Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Unable to save workspace with indicator

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

    Unable to save workspace with indicator

    Hi,
    when i like save workspace with my own indicator, i'm getting this error


    2018-11-01 21:44:53:779|3|4|Could not save indicator 'PHPivots:' There was an error reflecting type 'NinjaTrader.NinjaScript.Indicators.PHPivots'.


    But indicator is running propertly in chart and this error in log doesn't tell anythink where is error, any idea how to debug/solve this issue?

    Best regards
    Patrik.

    #2
    Hello patriczek,

    This error would generally stem from the script not being able to be saved or what is known as serialized. This is often caused by the public properties you have used but can also come from other complex scenarios.

    I would suggest doing some general tests to find what part of the script is causing this to happen.

    A good first test would be to comment out all the custom logic you created including public properties, just make the script into a shell that does nothing. Then reapply the script and see if it can be saved. This helps to know that the script structure is valid. After doing this, uncomment just the public properties and where you set their defaults. Reapply the script and test again after doing this change, is there a problem saving or does the script save?

    You could continue doing these types of tests until you locate a specific part of the script that fails. If it is not apparent why that code is failing, we could review that together to see why that would be. You can see this type of error in some complex inheritance situations along with some public properties. The error is fairly general so some troubleshooting will be needed to isolate what the cause is.

    I look forward to being of further assistance.

    Comment


      #3
      Hi Jesse

      i just finish debugging, i had public dictionary when i switched this dict to private all was repaired and work well.

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Geovanny Suaza, 02-11-2026, 06:32 PM
      0 responses
      558 views
      0 likes
      Last Post Geovanny Suaza  
      Started by Geovanny Suaza, 02-11-2026, 05:51 PM
      0 responses
      324 views
      1 like
      Last Post Geovanny Suaza  
      Started by Mindset, 02-09-2026, 11:44 AM
      0 responses
      101 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by Geovanny Suaza, 02-02-2026, 12:30 PM
      0 responses
      545 views
      1 like
      Last Post Geovanny Suaza  
      Started by RFrosty, 01-28-2026, 06:49 PM
      0 responses
      547 views
      1 like
      Last Post RFrosty
      by RFrosty
       
      Working...
      X