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

UI Properties Sub Group (ExpandableObjectConverter)

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

    UI Properties Sub Group (ExpandableObjectConverter)

    Hello,

    I am trying to create a subgroup with a few fields. I tried to follow the example
    ExpandableClassPropertyBrushesExample_NT8.zip
    The example is not very clear, and so my results are not working as expected.

    To simplify it, I created a little example and attached the code. Could you let me know what needs to be changed?
    BWPropertiesSub.zip
    Also, I would like these properties to be saved as part of the temple.


    #2
    Hello Shai Samuel,

    Thank you for your post.

    Are you looking to have Set 1, Set 2, and Set 3 as sub groups within the Parameters section, or would it work for your use case to have each set as a separate properties section? You should be able to set the GroupName in the DisplayAttribute for each property, and then you could even use the CategoryOrderAttribute to set the different groups in a specific order as needed and this may meet your needs. Here are the relevant links:I look forward to your clarification.​
    Emily C.NinjaTrader Customer Service

    Comment


      #3

      Dear Emily,

      I was able to complete the serializing task as well and was able to save it to a temple, and then load it. I noticed some people struggle with it, I have attached the code, and you can use it as an example.

      Thank you for your support.
      Attached Files
      Last edited by Shai Samuel; 06-01-2023, 09:18 AM. Reason: Update the example

      Comment


        #4
        Shai Samuel Good job with this.
        Bruce DeVault
        QuantKey Trading Vendor Services
        NinjaTrader Ecosystem Vendor - QuantKey

        Comment


          #5
          Sorry, I don't think I follow your question. Could you clarify?
          Bruce DeVault
          QuantKey Trading Vendor Services
          NinjaTrader Ecosystem Vendor - QuantKey

          Comment


            #6
            QuantKey_Bruce​,​

            I am challenged now with adding this to the toggling option (propertyDescriptorCollection). The item in the PropertyDescriptorCollection is the entire class and not the individual fields. Any ideas?​​

            Comment


              #7
              I am using SampleIndicatorTypeConverter_NT8.zip to toggle on and off (hide) properties from the UI based on other properties value. The ones I would like to hide are removed for the PropertyDescriptorCollection.

              With my the class as an item in the UI property, the entire class is an item, but not any of it's fields. That means that I can toggle the entire class (Set1, Set2 ...) but not any of it's fields, which are what required. Any idea?

              Comment


                #8
                No, I can't immediately think of a solution for that. There might be one though - perhaps bltdavid or NinjaTrader Support might know.
                Bruce DeVault
                QuantKey Trading Vendor Services
                NinjaTrader Ecosystem Vendor - QuantKey

                Comment


                  #9
                  Originally posted by Shai Samuel View Post
                  I am using [ATTACH]n1254032[/ATTACH] to toggle on and off (hide) properties from the UI based on other properties value. The ones I would like to hide are removed for the PropertyDescriptorCollection.

                  With my the class as an item in the UI property, the entire class is an item, but not any of it's fields. That means that I can toggle the entire class (Set1, Set2 ...) but not any of it's fields, which are what required. Any idea?
                  Hello Shai Samuel,

                  Thank you for the information.

                  Since you are using a class to create a sub group within the Parameters section, this won't allow the full flexibility and options available in the SampleIndicatorTypeConverter example. If you want to be able to toggle items within Set1, Set2, etc. then you will need to set them up as their own groups, rather than sub groups, using GroupName in the DisplayAttribute as previously mentioned. I understand this may be a compromise, though you will need to choose between separating your properties into groups with GroupName and allowing toggling the properties within that group, or if you prefer to have the sub groups within Parameters you can only toggle the entire class and not individual fields within the class.

                  Please let us know if we may be of further assistance.
                  Emily C.NinjaTrader Customer Service

                  Comment


                    #10
                    Thank you Emily. I understand the current limit here. I now see the same issue with Optimization in a Strategy Optimizer, as these fields are not recognized by the optimizer, and so they don't have Min/Max options.

                    I see this as an important option, nor just a UI issue. Adding a class allows a more efficient way to handle functionality when you want to replicate functions such as in this case of multiple
                    "Sets". Therefore, I as to add the whole thing as a feature. Please add this as a request.

                    Comment


                      #11
                      Hello Shai Samuel,

                      Thank you for your reply and for the feedback.

                      I have submitted this as a feature request to the Development Team. I will follow up with an internal tracking number for your reference as soon as it is created. If there is an existing feature request, I will have your vote added and provide you with the existing tracking number.

                      Thanks in advance for your patience.
                      Emily C.NinjaTrader Customer Service

                      Comment


                        #12
                        Hello Shai Samuel,

                        Thanks for your patience.

                        The internal tracking number for your feature request is SFT-5952. Please reference this internal tracking number when contacting Platform Support if you ever have questions regarding this feature request.

                        When a feature request is implemented, you'll find a description of the new feature in the release notes:Thank you for using NinjaTrader.​
                        Emily C.NinjaTrader Customer Service

                        Comment

                        Latest Posts

                        Collapse

                        Topics Statistics Last Post
                        Started by PaulMohn, Today, 05:00 AM
                        0 responses
                        7 views
                        0 likes
                        Last Post PaulMohn  
                        Started by ZenCortexAuCost, Today, 04:24 AM
                        0 responses
                        6 views
                        0 likes
                        Last Post ZenCortexAuCost  
                        Started by ZenCortexAuCost, Today, 04:22 AM
                        0 responses
                        3 views
                        0 likes
                        Last Post ZenCortexAuCost  
                        Started by SantoshXX, Today, 03:09 AM
                        0 responses
                        16 views
                        0 likes
                        Last Post SantoshXX  
                        Started by DanielTynera, Today, 01:14 AM
                        0 responses
                        5 views
                        0 likes
                        Last Post DanielTynera  
                        Working...
                        X