Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Error on loading NT

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

    Error on loading NT

    I keep getting a warning when I boot up NT that says one of my custom indicator NT properties is out of range. I have the range set where I want it and I have set the property to an in-range value within the body of OnStateChange() State==State.SetDefaults. What else do I need to do to stop this error message coming up every time I load NT?

    [NinjaScriptProperty]
    [Range(.1, int.MaxValue)]
    [Display(Name="ATR multiplier", Description="Determines box height", Order=1, GroupName="Parameters")]
    public double atrMultiplier
    { get; set; }

    #2
    Hi Chippy, thanks for posting. The MaxValue should be double.MaxValue because int.MaxValue goes higher than what a double-precision variable can store. If your getting this error it means it's not being set at all or it's being set to an illegal value. You would need to reduce the script down a bit to find the exact cause of the error message.

    Kind regards,
    -ChrisL

    Comment

    Latest Posts

    Collapse

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