Click to See Complete Forum and Search --> : List Box Scrollbar


scathenC
July 28th, 2006, 03:07 AM
Hi all,

Does anyone know how to get the HWND of a scrollbar within a list box
that has the WS_VSCROLL style?

I know that the parent window will recieve the WM_VSCROLL message
containing the HWND when the scrollbar is used, but I need to access
it near creation.

C

ovidiucucu
July 28th, 2006, 08:06 AM
Unlike a scroll-bar control, a window's standard scroll bar (i.e. for a window having WS_VSCROLL/WS_HSCROLL style(s)) is not a window so has no associated HWND.

JohnCz
July 30th, 2006, 09:46 AM
I know that the parent window will recieve the WM_VSCROLL message containing the HWND when the scrollbar is usedIn addition to Ovidui’s post: Check lParam for WM_VSCROLL and see that is 0; lParam is a scroll bar handle.