Link to home
Start Free TrialLog in
Avatar of skibud2
skibud2

asked on

Resize a combo box to a form view

How do I Resize a combo box to a form view? What message handler should I use?
Avatar of skibud2
skibud2

ASKER

I basically want the combobox to be the size of the form view (or a little less). The formview can be resized.
ASKER CERTIFIED SOLUTION
Avatar of gurly
gurly

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of skibud2

ASKER

Awesome Answer.. I am just wondering is it possible to use the setWindowPos to do something like this? Thats what I was trying and I was getting a ASSERT Error. I tried
m_combl.SetWindowPos(NULL,10,10,cx-10,cy-10, SWP_NOREDRAW);
Appreciate the help
-Mike
Where do you place that line and get an ASSERT ?

I tried the same and it worked ok.

maybe you didn't check that the window is alive ?
--->  if (::IsWindow(m_oCombo.m_hWnd))

Glad to be of help, anyway.