Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Saving indicator settings multiple workspaces

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

    Saving indicator settings multiple workspaces

    I have multiple workspaces that use the same custom indicator. How do I save each indicator's settings so that when I open the workspace they maintain the indicator settings?

    #2
    Hello habibalex,

    An indicator with properly serialized inputs will have all parameters saved with the workspace.

    Are you finding that you are setting parameters, saving the workspace, and then after closing and re-opening the workspace the parameters are different?

    Are you asking if indicator settings can be saved with a template to be applied to a new chart?
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Are you finding that you are setting parameters, saving the workspace, and then after closing and re-opening the workspace the parameters are different?
      Yes

      These are the in the Properties section, is there a way I can check to make sure they are serialized correctly?

      Code:
      [XmlIgnore]
      		[Display( Name = "Scale", GroupName = "A settings",Description="Colors for bar.")]
              public float Scale{
      			get { return scale;}
      			set{ scale = value;}
      		}
      		
      		[XmlIgnore]
      		[Display( Name = "Use Outline", GroupName = "A settings",Description="Outlines everything.")]
              public bool UseOutline{get;set;}

      Comment


        #4
        I think I needed to see what this was, I kept looking for properties

        Comment


          #5
          Hello habibalex,

          I would expect the Scale float to be saved with the workspace but not the UseOutline bool which has XmlIgnore().

          Workspaces and templates are xml files. If XmlIgnore is used, these values will not be saved.

          May I confirm the Scale float value is not being saved?

          If yes, may I test this on my end?

          To export a NinjaTrader 8 NinjaScript do the following:
          1. Click Tools -> Export -> NinjaScript...
          2. Click the 'add' link -> check the box(es) for the script(s) you want to include
          3. Click the 'Export' button
          4. Enter a unique name for the file in the value for 'File name:'
          5. Choose a save location -> click Save
          6. Click OK to clear the export location message

          By default your exported file will be in the following location:
          • (My) Documents/NinjaTrader 8/bin/Custom/ExportNinjaScript/<export_file_name.zip>


          Below is a link to the help guide on Exporting NinjaScripts.



          The Browseable attribute prevents the input from showing in the Indicator property grid at all. Basically this will hide that input in the parameters window completely when set to false.
          Chelsea B.NinjaTrader Customer Service

          Comment


            #6
            Hi Chelsea, i just deleted the XMLIgnore statements and everything is saving properly. I have a few more settings that I will test after the market closes today.

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by Geovanny Suaza, 02-11-2026, 06:32 PM
            0 responses
            561 views
            0 likes
            Last Post Geovanny Suaza  
            Started by Geovanny Suaza, 02-11-2026, 05:51 PM
            0 responses
            325 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
            547 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