WM_VSCROLL

This message is sent when the user clicks the vertical scroll bar.

Parameter Description  

wParam Contains a scroll-bar code that specifies the user's scrolling request. It can be any one of the following values:  
  Value Meaning
  SB_BOTTOM Scroll to bottom.
  SB_ENDSCROLL End scroll.
  SB_LINEDOWN Scroll one line down.
  SB_LINEUP Scroll one line up.
  SB_PAGEDOWN Scroll one page down.
  SB_PAGEUP Scroll one page up.
  SB_THUMBPOSITION Scroll to absolute position. The current position is provided in the low-order word of lParam.
  SB_THUMBTRACK Drag thumb to specified position. The current position is provided in the low-order word of lParam.
  SB_TOP Scroll to top.
lParam If the message is sent by a scroll-bar control, the high-order word of the lParam parameter identifies the control. If the message is sent as a result of the user clicking a pop-up window's scroll bar, the high-order word is not used.  

Comments

The SB_THUMBTRACK message typically is used by applications that give some feedback while the thumb is being dragged.

If an application scrolls the document in the window, it must also reset the position of the thumb by using the SetScrollPos function.