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

Indicator could not be serialized

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

    Indicator could not be serialized

    Hello, dear support

    I am writing now one indicator and when I try to save it into template I get the next message:
    "Indicator "Ninjatrader.Indicator...." could not be serialized. Please refer help for more information on serializing indicators.

    I am using followed properties:

    Code:
    		[Description("Bar span to consider for breakouts")]
    		[GridCategory("Parameters")]
    		public int Span {
    			get { return span; }
    			set { span = Math.Max(1, value); }
    		}
    
    		[Description("What to display (0=none, 1=dots, 2=lines, 3=both)")]
    		[GridCategory("Parameters")]
    		[Gui.Design.DisplayNameAttribute("Display Type")]
    		public int DisplayType {
    			get { return displayType; }
    			set { displayType = Math.Max(0, value); }
    		}
    				
    		[Description("Display/Hide switch points")]
    		[GridCategory("Parameters")]
    		public bool DisplayDiamonds {
    			get { return displayDiamonds; }
    			set { displayDiamonds = value; }
    		}
    And Misc to access some data from other indicators/strategies

    Code:
    		public  AkPoint FirstPoint
    		{
    			get { return patterns.P1; }
    		}		
    	
    		public  AkPoint SecondPoint
    		{
    			get { return patterns.P2; }
    		}		
    		
    		public  AkPoint CurrentPoint
    		{
    			get
    			{
    				Update();
    				return patterns.Current;
    			}
    		}		
    		
    		public  AkDirrection Dirrection
    		{
    			get
    			{
    				Update();
    				return patterns.Dirrection;
    			}
    		}	
    		
    		public  BoolSeries Switcher
    		{
    			get
    			{
    				return this.switcher;
    			}
    		}		
    
    		public AkPoint LastHighPoint
    		{
    			get
    			{
    				Update();
    				return lastHigh;
    			}
    		}
    		
    		public AkPoint LastLowPoint
    		{
    			get
    			{
    				Update();
    				return lastLow;
    			}
    		}
    
    		public ArrayList Points
    		{
    			get { return this.points; }
    		}
    
    		public ArrayList LowPoints
    		{
    			get { return this.lowPoints; }
    		}
    
    		public ArrayList HighPoints
    		{
    			get { return this.highPoints; }
    		}
    Could you help me , please with that issue?

    #2
    Hello akushyn,

    Thank you for your note.

    Without the full code I'm unable to test on my end.

    The message you're getting suggests some of your indicators are not coded properly for serialization. Serialization is most commonly needed for user definable color inputs and allows these inputs to be saved in workspaces and chart templates. If these are your own custom coded indicators, a guide to serializing color inputs is available here:
    http://ninjatrader.com/support/forum...ead.php?t=4977

    If you are unable to resolve the issue, please upload a copy of the full code so we can take a look on our end.

    To export a NinjaScript from NinjaTrader 7 do the following:
    From the Control Center window select File -> Utilities-> Export NinjaScript...
    Select the file in the left column then click “>”, then press export and name the file.
    Then attach that file you saved; under My Docs>NT8>Bin>Custom>Select the downloaded .zip file.


    Please let us know if you need further assistance.
    Alan P.NinjaTrader Customer Service

    Comment


      #3
      Its a private indicator. I could send you on email.
      Tell me your email, please.

      Comment


        #4
        Hello akushyn,

        Please send an email to platformsupport[at]ninjatrader[dot]com with Attn: Alan P in the Subject line. Also within the email please include a link to this thread as well as the files.

        I look forward to receiving your email.
        Alan P.NinjaTrader Customer Service

        Comment


          #5
          Originally posted by NinjaTrader_AlanP View Post
          Hello akushyn,

          Please send an email to platformsupport[at]ninjatrader[dot]com with Attn: Alan P in the Subject line. Also within the email please include a link to this thread as well as the files.

          I look forward to receiving your email.
          Check your inbox,plz

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by ezrollin, Yesterday, 09:01 PM
          1 response
          19 views
          0 likes
          Last Post ezrollin  
          Started by FutTrader9000, Yesterday, 06:20 PM
          0 responses
          29 views
          0 likes
          Last Post FutTrader9000  
          Started by junkone, Yesterday, 05:48 PM
          0 responses
          23 views
          0 likes
          Last Post junkone
          by junkone
           
          Started by Futurestrader00, Yesterday, 05:10 PM
          1 response
          29 views
          0 likes
          Last Post NinjaTrader_ShawnB  
          Started by Gerik, 03-08-2021, 01:25 AM
          5 responses
          49 views
          0 likes
          Last Post NinjaTrader_ShawnB  
          Working...
          X