SpinEdit Not Honoring Max/Min Limits

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #37374
    TAZ
    Participant

    This is a subtle thing.

    If you have both Max and Min set to 0, there is no maximum or minimum number you can enter (with the exception of the type limit). In other words, no limits imposed.

    Set Max = 5 and Min = 0. Then if you try to set Max > 5, Max will not allow this and will stay at a value of 5.

    Based on the same limits, if you try to set Min < 0, Min allows that negative number. Min is not working to stop the value from going less than 0.

    Set Max = 0 and Min = -5. Then if you try to set Min < -5, Min will not allow this and will stay at a value of 0.

    Based on the same limits, if you try to set Max > 0, Max allows that positive number. Max is not working to stop the value from going greater than 0.

    Basically you have to set both Max and Min to NOT 0 to enforce the limits. Placing either Max or Min to 0 will NOT enforce that limit. Surely this is not by design.

    I am not sure about this problem(?) on other components that have these Max/Min limits. I hope this is isolated to the spin edit.

    I have a real world case where Max = 5 and Min = 0. Cannot place Min = 1 or -1 because it would defeat the purpose of using these limits.

    Version 11.26

    #56267
    TAZ
    Participant

    There is one thing that puzzles me, “AllowNegative” property. It does prevent negative numbers (if unchecked) when you have a Min set to 0.

    However, it will not stop Max = 0 and Min = negative problem of the Max going greater than 0. Guess you could have a “AllowPositive” property but I doubt that would be beneficial.

    #56309
    Support
    Keymaster

    Hello

    Sometimes it's required to have unlimited minimal value, but limited max value. Or unlimited max value with limited min value.

    We have made 0 as unlimited for this purposes. If value must have 0 as minimal, then we can use AllowNegative property, you are right.

    Maybe, the AllowPositive property should be added too.

    #56311
    TAZ
    Participant

    Based on your reply I would agree.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.