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

Indicator parameter cannot be set to default

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

    Indicator parameter cannot be set to default

    Hi everyone!
    After making the code to prolonged and complicated, parameter values cannot be set to default. I can't figure it out anymore, all of the parameter are disabled.

    // Create our user definable color input
    [XmlIgnore()]
    [Description("Color for box region")]
    [Gui.Design.DisplayName("Display Background")]
    [GridCategory("Trade Activity Display")]
    public Color BoxColor
    {
    get { return boxColor; }
    set { boxColor = value; }
    }

    // Serialize our Color object
    [Browsable(false)]
    public string BoxColorSerialize
    {
    get { return NinjaTrader.Gui.Design.SerializableColor.ToString( boxColor); }
    set { boxColor = NinjaTrader.Gui.Design.SerializableColor.FromStrin g(value); }
    }

    I think serializing the parameter is correct and I think this is not the main reason why I can't set the parameter to default. I load other type of indicator and works correctly except this indicator. I try to rewrite the codes but I am failed. Any Idea why I can't set to default all parameter of my indicator?
    Attached Files

    #2
    Hello Danville,

    Thank you for your post.

    Can you attach a sample of script that you are running into problems with or you may send me the script to support[at]ninjatrader[dot]com with ATTN Cal in the subject line and a reference to this thread.
    Cal H.NinjaTrader Customer Service

    Comment


      #3
      Thanks for the reply!
      Which part of my script would you like to see? Anyway thanks, I will just try to figure it out. I only need suggestion, If someone encounter this already. Any help would be appreciated.

      Comment


        #4
        Danville,

        I wanted to test out the script on my end to see if I can narrow down what is causing the error.

        Would you be willing to send it to me through email instead?
        support[at]ninjatrader[dot]com
        Cal H.NinjaTrader Customer Service

        Comment


          #5
          Hello NT_Cal

          Thanks for your concern.

          I figure it already, The cause of it is I am using public declaration of variable, I must be careful next time. Charge to experience.

          Comment

          Latest Posts

          Collapse

          Topics Statistics Last Post
          Started by kujista, Today, 06:23 AM
          4 responses
          14 views
          0 likes
          Last Post NinjaTrader_ChelseaB  
          Started by traderqz, Yesterday, 09:06 AM
          2 responses
          16 views
          0 likes
          Last Post traderqz  
          Started by traderqz, Today, 12:06 AM
          3 responses
          6 views
          0 likes
          Last Post NinjaTrader_Gaby  
          Started by RideMe, 04-07-2024, 04:54 PM
          5 responses
          28 views
          0 likes
          Last Post NinjaTrader_BrandonH  
          Started by f.saeidi, Today, 08:13 AM
          1 response
          8 views
          0 likes
          Last Post NinjaTrader_ChelseaB  
          Working...
          X