Visual C++ and MFC Fundamentals Chapter 18: Progress-Based Controls
}
As mentioned already, you can resize a scroll bar control to have the dimensions of your
choice. If you are programmatically creating the control, it would assume the size
allocated during design or the nWidth and the nHeight members of the rect argument of
the Create() method. Internally, the operating system has a default width for a vertical
scroll bar and a default height for a horizontal scroll bar. If you prefer to use those default
values, you have various options.
If you are visually creating the scroll bar, change the value of the Align property. Imagine
you resize the scroll bar as follows:
If you set the Align property to Top/Left for a horizontal scroll bar, it would keep its top
border and bring its border up to get the default height set by the operating system:
If you select this same value for a vertical scroll bar, it would keep its left border and
narrow the control to assume the default width of the operating system: