Alexander Rafferty
Alexander Rafferty

Reputation: 6233

Combobox hidden on resize

Whenever I resize my controls in my window, in response to a WM_SIZE message, they resize and redraw themselves fine. But my combobox control (a dropdown list) disappears whenever I give it a resize message, until I hover over it to bring it back.

There are two possibilities, either it is not redrawing when I resize it, or it is being hidden by my tab control. So how would I solve this problem?

Upvotes: 3

Views: 567

Answers (1)

Brian R. Bondy
Brian R. Bondy

Reputation: 347556

I think the problem is probably the tab control hiding your control.

You can use SetWindowPos to set its z-order with specifying SWP_NOMOVE and SWP_NOSIZE.

You can also use BringWindowToTop to bring the combobox to the top of your z-order.

Upvotes: 4

Related Questions