Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Default Enum Value not displaying

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

    Default Enum Value not displaying

    I've got an enum that I use as a drop down that I've defaulted to a value, but it seems to not use my default value.

    Is there something more I need to do to get default Enums to work?

    Code:
    public enum TF {	FALSE,TRUE	}

    Code:
    private TF 	fibretracement = TF.FALSE;


    Code:
    		[Description("Add Fibonacci Retracement")]
    		[Category(" A. MULTI-DIVERGENCE")]
    		public TF FibRetracement
    		{
    			get { return fibretracement; }
    			set { fibretracement = value; }
    		}
    This seems to still default me to TRUE instead of the defaulted FALSE.


    Thanks

    Matt

    #2
    tazatek,

    Hmm. Have you set a default for this script via the UI menu already? If so that would overwrite what you have in your code.
    Josh P.NinjaTrader Customer Service

    Comment


      #3
      possibly.... I forgot about that functionality. I might have set this while I was "playing".

      I've reset it and it works (as expected).

      Thanks

      Matt

      Comment

      Latest Posts

      Collapse

      Topics Statistics Last Post
      Started by Geovanny Suaza, 02-11-2026, 06:32 PM
      0 responses
      621 views
      0 likes
      Last Post Geovanny Suaza  
      Started by Geovanny Suaza, 02-11-2026, 05:51 PM
      0 responses
      359 views
      1 like
      Last Post Geovanny Suaza  
      Started by Mindset, 02-09-2026, 11:44 AM
      0 responses
      105 views
      0 likes
      Last Post Mindset
      by Mindset
       
      Started by Geovanny Suaza, 02-02-2026, 12:30 PM
      0 responses
      562 views
      1 like
      Last Post Geovanny Suaza  
      Started by RFrosty, 01-28-2026, 06:49 PM
      0 responses
      567 views
      1 like
      Last Post RFrosty
      by RFrosty
       
      Working...
      X