How to set minimum and maximum values for an Expression Slider Control
clamp(value, min=0, max=255);
...sometimes I use a little bit modified version of this expression...
For example, you want "teach" slider to take only whole numbers from 1 to 5.
So this expression help you:
round = Math.round(value);
min = 1; //minimum value
max = 5; //maximum value
clamp(round, min, max);
Or the whole of that last bit in one line...
clamp(Math.round(value), min = 1, max = 5);
Note: You don't need the min = and max=, but it can be helpful in remembering which arguments are which.