How to change the position of the Vertical Scrollbar of a window?
I'm referring to the position in xy, for example set it in the middle of the window instead of the edges.
CodePudding user response:
You cannot reposition a scrollbar that is built-in to a window. You will have to disable the native scrollbar (remove the window's WS_HSCROLL
/WS_VSCROLL
style) and then create a separate ScrollBar control as a child of the window. Then you can position that child wherever you want, using the x
/y
parameters of CreateWindow/Ex()
or SetWindowPos()
.