Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Hide settings in PriceLevels

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

    Hide settings in PriceLevels

    I've created a drawing tool based on a built-in tool that contains PriceLevels code.
    I would like to hard code certain levels and block them from being seen/altered in the properties of the tool. If I could disable access to the properties of the tool altogether, that would be great, but not necessary. These levels are located in the State.SetDefaults area, and I've already removed the (State == State.Configure) section. But they still show when the user opens the tool properties.
    Thanks for any assistance.

    #2
    Hello robertcooney,

    The price levels are added dynamically.

    You could use custom logic in the PriceLevelTypeConverter to remove certain indexes in the collection..
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      Thanks Chelsea. I read through that article and the TypeConverter link (https://docs.microsoft.com/en-us/pre...ectedfrom=MSDN).
      Unfortunately it is a bit over my head.

      Comment


        #4
        Hello robertcooney,

        What you are wanting to do would be extremely complex and would require very advanced custom c# code.

        You can also contact a professional NinjaScript Consultant who would be eager to create or modify this script at your request or assist you with your script. The NinjaTrader Ecosystem has affiliate contacts who provide educational as well as consulting services. Please let me know if you would like our NinjaTrader Ecosystem team follow up with you with a list of affiliate consultants who would be happy to create this script or any others at your request or provide one on one educational services.

        The most likely place the custom logic would go is in the PropertyDescriptorCollection override when checking if the property is a Value, some custom logic here would check the index of the collection and remove items from the collection for certain indexes.
        Chelsea B.NinjaTrader Customer Service

        Comment

        Latest Posts

        Collapse

        Topics Statistics Last Post
        Started by CarlTrading, 03-31-2026, 09:41 PM
        1 response
        43 views
        0 likes
        Last Post NinjaTrader_ChelseaB  
        Started by CarlTrading, 04-01-2026, 02:41 AM
        0 responses
        20 views
        0 likes
        Last Post CarlTrading  
        Started by CaptainJack, 03-31-2026, 11:44 PM
        0 responses
        30 views
        1 like
        Last Post CaptainJack  
        Started by CarlTrading, 03-30-2026, 11:51 AM
        0 responses
        47 views
        0 likes
        Last Post CarlTrading  
        Started by CarlTrading, 03-30-2026, 11:48 AM
        0 responses
        38 views
        0 likes
        Last Post CarlTrading  
        Working...
        X