CWnd::OnHScroll 

afx_msg void OnHScroll( UINT nSBCode, UINT nPos, CScrollBar* pScrollBar );

Parameters

nSBCode

Specifies a scroll-bar code that indicates the user’s scrolling request. This parameter can be one of the following:

nPos

Specifies the scroll-box position if the scroll-bar code is SB_THUMBPOSITION or SB_THUMBTRACK; otherwise, not used. Depending on the initial scroll range, nPos may be negative and should be cast to an int if necessary.

pScrollBar

If the scroll message came from a scroll-bar control, contains a pointer to the control. If the user clicked a window’s scroll bar, this parameter is NULL. The pointer may be temporary and should not be stored for later use.

Remarks

The framework calls this member function when the user clicks a window’s horizontal scroll bar.

The SB_THUMBTRACK scroll-bar code typically is used by applications that give some feedback while the scroll box is being dragged.

If an application scrolls the contents controlled by the scroll bar, it must also reset the position of the scroll box with the SetScrollPos member function.

Note   This member function is called by the framework to allow your application to handle a Windows message. The parameters passed to your function reflect the parameters received by the framework when the message was received. If you call the base-class implementation of this function, that implementation will use the parameters originally passed with the message and not the parameters you supply to the function.

CWnd OverviewClass MembersHierarchy Chart

See Also   CWnd::SetScrollPos, WM_VSCROLL, WM_HSCROLL