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

Changing value of Property, when another property changes

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

    Changing value of Property, when another property changes

    I am using IndicatorBaseConverter to toggle some input properties visibility On/Off from the Indicator UI.

    I would like to change the existing value of a property, base on value of another property.

    For example, if I have a property such as fastPeriod, I would like to set the value 1 to it, if UsePeriod is set false using the UI.

    #2
    Hello Shai Samuel,

    Thanks for your post.

    Please see this reference sample from the NinjaTrader 8 help guide which demonstrates using a TypeConverter to customize property grid behavior:




    There are 5 different use cases demonstrated in the reference sample linked above.

    1. Dynamically manipulate what is displayed on the UI Property Grid
    a. Show / hide properties based on secondary input
    b. Disable / enable properties based on secondary input






    2. Customizing how a property is displayed
    a. Display "Friendly" enum values
    b. Re-implement a "bool" CheckBox as "Friendly" a ComboBox
    c. Display a custom collection / list with user defined values at run time






    Let me know if I may further assist.​
    Last edited by NinjaTrader_BrandonH; 10-04-2022, 06:59 AM.
    Brandon H.NinjaTrader Customer Service

    Comment


      #3
      NinjaTrader_BrandonH An observation on details in your post. The link (and its display) are incorrect, and have a space introduced in the text. Absolutely no doubt you entered everything correctly! This is a flaw in the Forum software that has been obvious for a long time. It sometimes introduces a space in the middle of text. When it happens, one can edit and repost, and that sometimes fixes it, but other times, the flaw persists. This should be fixed by the Forum software provider.

      Thanks.
      Multi-Dimensional Managed Trading
      jeronymite
      NinjaTrader Ecosystem Vendor - Mizpah Software

      Comment


        #4
        Thank you Brandon.

        My guess @jeronymite​ is that you are right. Anyway I found the correct like:
        https://ninjatrader.com/support/helpGuides/nt8/NT%20HelpGuide%20English.html?using_a_typeconverte r_to_custo.htm

        Comment


          #5
          Hello jeronymite and Shai Samuel,

          Thanks for your notes.

          I have reposted the link in post # 2 so that it leads to the correct reference sample and reported this behavior.

          Please let me know if I may assist further.
          Brandon H.NinjaTrader Customer Service

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by samish18, 04-17-2024, 08:57 AM
          16 responses
          55 views
          0 likes
          Last Post samish18  
          Started by arvidvanstaey, Today, 02:19 PM
          3 responses
          9 views
          0 likes
          Last Post NinjaTrader_Zachary  
          Started by jordanq2, Today, 03:10 PM
          2 responses
          8 views
          0 likes
          Last Post jordanq2  
          Started by traderqz, Today, 12:06 AM
          10 responses
          18 views
          0 likes
          Last Post traderqz  
          Started by algospoke, 04-17-2024, 06:40 PM
          5 responses
          47 views
          0 likes
          Last Post NinjaTrader_Jesse  
          Working...
          X