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

Serialization Error

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

    #16
    Guys, this is not a damon but a limitation of XML serialization.

    XML serialization is a standard MS .NET technology which NT uses to persist e.g. your indicator settings. Unfortunately there are limitations with that technology. None of the NT standard indicators/strategies would suffer from that limitation but your custom indicators/strategies could (if not coded correctly to reflect these limitations).

    If you googled e.g. for "xml serialization .net" you would find several references on that subject.

    Comment


      #17
      Serialization error for standard EMA

      When backing up my workspace today I got once again a serialization error (see below). This time it was a standard NT indicator. It is likely that NT developpers have correctly coded EMA, but the demons are not impressed with this. I tried to backup several times, but only could do so after I had removed all EMAs. I then added them again, and this time NT would do the complete backup.

      This is my standard procedure for serialization errors. They do occur, and usually they are not reproducible.
      Attached Files

      Comment


        #18
        I never have seen that issue on a NT standard indicator before. It would be great to have scenario which would allow us to reproduce the problem.

        Comment


          #19
          Not reproducible

          It is not an important problem, as it only occurs during backups. The fact that standard NT indicators also suffer from serialization errors just shows that it is not the indicator code that produces this behaviour.

          Comment


            #20
            Your understanding is correct. I would speculate that it's a general issue regarding your installation. May be completely reinstalling .NET (and NT) would make a difference ?!?

            Comment


              #21
              I have already done this once. My installation is stable otherwise. NT uses 470 MB of RAM (3 GB installed for XP), there are no other issues except those relating to backfill.

              Comment


                #22
                Hmm .. then I'm of ideas for now.

                Comment


                  #23
                  Harry - i can confirm this kind of serialization-popup with a @EMA or @WMA i have it from time to time when saving a workspace.

                  if it happens - i put the indie off the chart + save workspace again + its OK. normaly i close workspace + NT then -- start new and all is fine - i can put the @WMA in and save -- everything OK then again.
                  it happens maybe once in a moth or 2 - no clue in wich special situations/combinations - but it happens - thats what i can confirm.

                  i share your thoughts to that :
                  It is not an important problem, but he fact that standard NT indicators also suffer from serialization errors just shows that it can not only be the indicator code that produces this behaviour.

                  BTW -
                  clean system
                  enaugh RAM
                  real stabil NT

                  Comment


                    #24
                    Still strange ... I just added some trace code to our new NT7 so get some more info in case that would happen on NT7 and it's new .NET 3.5 still.

                    Comment


                      #25
                      Like Dave in post #9 I encounter same serialization error on my custom indicator (NT6.5-15) which exposes publicly 1 BoolSeries when saving my Workspace. Indicator works fine. However exposing the BoolSeries publicly creates the issue. I've tried all solutions presented here, as well as repairing the db. To no avail.

                      Anyone find a solution to this since ?

                      Comment


                        #26
                        Welcome to our forums DynaMike - do you see the same issue when working with the SampleBoolSeries sample code we provide?

                        BertrandNinjaTrader Customer Service

                        Comment


                          #27
                          Hi Bertrand,

                          Thx for the reply. I did indeed see the same isssue with the sample code provided, however I resolved the issue by declaring the BoolSeries public in the variable section of the indicators.
                          Regardless the fact that I have no code at all in the Properties section to expose the BoolSeries I'm now able to call it in strategies.
                          While the latter does not seem to my layman's programmer mind as the proper way to expose the Series, it works !!

                          Comment


                            #28
                            Serialization Error

                            I know this thread is over a year old, but I got the 'error' message this evening.

                            Checked for the declared 'public' in varibles, not an issue.

                            Did the remove indie, then reinstalled it...and that fixed it.

                            I know you guys at NT are always looking for feedback, so there you go.

                            Also, thanks for keeping these threads open, a simple solution was available because of it.

                            Comment


                              #29
                              Originally posted by Harry View Post
                              I have already done this once. My installation is stable otherwise. NT uses 470 MB of RAM (3 GB installed for XP), there are no other issues except those relating to backfill.
                              Your understanding is correct. I would speculate that it's a general issue regarding your installation. May be completely reinstalling .NET (and NT) would make a difference ?!?
                              ____________________
                              virtual assistant

                              Comment


                                #30
                                This is an old - but harmless - NinjaTrader bug. From time to time NinjaTrader refuses to save a chart template or a workspace and a message pops up that an indicator could not be serialized.

                                Sometimes this points to a coding error in a custom indicator. But from time to time this message also is triggered for system indicators and other indicators that have no coding errors.

                                If this happens, just shut down and restart NinjaTrader, then recreate that workspace or template and it should work without any problems.

                                Comment

                                Latest Posts

                                Collapse

                                Topics Statistics Last Post
                                Started by Irukandji, Today, 04:58 AM
                                0 responses
                                2 views
                                0 likes
                                Last Post Irukandji  
                                Started by fitspressoburnfat, Today, 04:25 AM
                                0 responses
                                2 views
                                0 likes
                                Last Post fitspressoburnfat  
                                Started by Skifree, Today, 03:41 AM
                                1 response
                                4 views
                                0 likes
                                Last Post Skifree
                                by Skifree
                                 
                                Started by usazencort, Today, 01:16 AM
                                0 responses
                                1 view
                                0 likes
                                Last Post usazencort  
                                Started by kaywai, 09-01-2023, 08:44 PM
                                5 responses
                                604 views
                                0 likes
                                Last Post NinjaTrader_Jason  
                                Working...
                                X