Win32: Reading WS_VSCROLL style from a combo box (or list box)
Posted
by Adam Tegen
on Stack Overflow
See other posts from Stack Overflow
or by Adam Tegen
Published on 2010-06-08T19:11:49Z
Indexed on
2010/06/08
20:22 UTC
Read the original article
Hit count: 160
I'm iterating through the controls in a dialog and I'm trying to determine if a combobox was created with the WS_VSCROLL style.
The style, obtained from GetWindowLong(hwnd, GWL_STYLE)
, doesn't contain the WS_VSCROLL bit (0x200000), even when I know it was set on create.
Clarification: I am looking to see if the ComboBox was created with the WS_VSCROLL style. Calling GetWindowLong() (or using spy++) to get the style of the combo's listbox will include WS_VSCROLL if a scrollbar is needed to based on the current contents of the list.
I am trying to determine if the ComboBox was created with WS_VSCROLL, not if a scrollbar is currently visible.
© Stack Overflow or respective owner