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

Adding a list to Indicator properties

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

    Adding a list to Indicator properties

    Hello,

    Can you help me with me the proper script to add a list in the Indicator properties section that I can then populate via the indicator property settings.

    I have tried with no success;

    [NinjaScriptProperty]
    [Display(ResourceType = typeof(Custom.Resource), Name = "list", GroupName = "6. list", Order =1)]
    public List<double> Levels { get; set; }

    I see the option in properties when i open up the UI but it will not take any inputs.

    I guess I have to initiate it this somewhere else in the code, possibly onstatechange but i'm not sure?

    Thanks

    #2
    Hello b16_aln,

    A custom type converter will need to be used.

    I recommend using the Use Case #5 example from the SampleIndicatorTypeConverter example.

    Below is a link to the reference sample in the help guide.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Originally posted by NinjaTrader_ChelseaB View Post
      Hello b16_aln,

      A custom type converter will need to be used.

      I recommend using the Use Case Uncategorized Groups example from the SampleIndicatorTypeConverter example.

      Below is a link to the reference sample in the help guide.
      https://ninjatrader.com/support/help...r_to_custo.htm
      Hey Chelsea, link seems to be broken.

      Comment


        #4
        Hi Jake, Here is the link to the full example:

        Chris L.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by frslvr, 04-11-2024, 07:26 AM
        9 responses
        123 views
        1 like
        Last Post caryc123  
        Started by rocketman7, Today, 09:41 AM
        4 responses
        16 views
        0 likes
        Last Post rocketman7  
        Started by selu72, Today, 02:01 PM
        1 response
        9 views
        0 likes
        Last Post NinjaTrader_Zachary  
        Started by WHICKED, Today, 02:02 PM
        2 responses
        16 views
        0 likes
        Last Post WHICKED
        by WHICKED
         
        Started by f.saeidi, Today, 12:14 PM
        8 responses
        21 views
        0 likes
        Last Post f.saeidi  
        Working...
        X