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

Changed indicator settings not saved with chart

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

    Changed indicator settings not saved with chart

    Hi,

    I just finished working on a new indicator. It works fine, but any changes made to the default settings in the indicator window aren't saved with the chart. I've never run across this before; and don't know what is causing it. Is there some flag that can to be set to ensure that changes are saved?

    Thanks-

    #2
    Hello palinuro,

    Thanks for the post. Can you please clarify "changes made to the default settings"? Does this mean you are right clicking > Save as Default or just setting values for user defined inputs?

    What are you expecting to see on the chart? Updated parameters when you change user defined inputs?
    Ryan M.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by palinuro View Post
      Hi,

      I just finished working on a new indicator. It works fine, but any changes made to the default settings in the indicator window aren't saved with the chart. I've never run across this before; and don't know what is causing it. Is there some flag that can to be set to ensure that changes are saved?

      Thanks-
      Any inputs that are not serializable, if changed from the defaults, will not be saved with the indicator, unless you make your own arrangements to serialize such.

      Comment


        #4
        Thanks for the quick responses.

        I've serialized the colors; the others are just integers.

        By 'changes made to the default settings' I mean both:
        - changing the values for the chart, but they revert to the original values when I reopen the chart, and
        - right clicking for Save as Default. They aren't.
        Neither works.

        Perhaps also relevant: every variable is visible in the indicator's signature, not just the ones in the "Parameters" GridCategory (i.e., including colors etc.). (I've noticed this with some other indicators I've downloaded from other sites, too.)

        Comment


          #5
          Thanks for the reply. Do you have a code snippet or a file we could use to see this here?
          Ryan M.NinjaTrader Customer Service

          Comment


            #6
            I found the culprit while looking for a code snippet to send - while copying and pasting I had forgotten to delete "XMLIgnore" in the Properties section.

            Thanks for the response!

            Comment


              #7
              Great you were able to spot it. Thanks for follow up here, palinuro.
              Ryan M.NinjaTrader Customer Service

              Comment


                #8
                Actually I now have a follow-up question:
                Every variable is now also included in the signature for the indicator. Is there a way to prevent that?

                Comment


                  #9
                  The method signature is generated based on user defined inputs. There is no way to have a variable function as an input, yet not be part of the method signature.
                  Ryan M.NinjaTrader Customer Service

                  Comment


                    #10
                    palinuro

                    By signature I assume you mean EMA(High,Period,etc)?

                    if so try

                    Code:
                    	public override string ToString()
                    		{
                    		return "";
                    		}

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by GussJ, 03-04-2020, 03:11 PM
                    15 responses
                    3,271 views
                    0 likes
                    Last Post xiinteractive  
                    Started by Tim-c, Today, 02:10 PM
                    1 response
                    8 views
                    0 likes
                    Last Post NinjaTrader_ChelseaB  
                    Started by Taddypole, Today, 02:47 PM
                    0 responses
                    2 views
                    0 likes
                    Last Post Taddypole  
                    Started by chbruno, 04-24-2024, 04:10 PM
                    4 responses
                    51 views
                    0 likes
                    Last Post chbruno
                    by chbruno
                     
                    Started by TraderG23, 12-08-2023, 07:56 AM
                    10 responses
                    403 views
                    1 like
                    Last Post beobast
                    by beobast
                     
                    Working...
                    X