As has already been pointed out to you, the method of the
CSliderCtrl
class to call is
SetRange
. If I were you, I would approach this problem in two phases. First, use a standard slider control, not owner drawn, and make sure you can set its range and get its position and value correctly. You may want to use this old article I wrote,
A smart edit and linked slider control[
^] as a testbed to accomplish this. After you have that working, then I would change it to be owner drawn. The key thing here is to separate the functionality so that you can verify one thing is not affecting the other.