NO

Author Topic: Resize a dialog box  (Read 3752 times)

Sanguis

  • Guest
Resize a dialog box
« on: July 02, 2008, 12:23:03 AM »
Hi,

I want to "embed" a dialog box. First I create the modeless dialog box and then, with
its window handle, I set its window style to WS_CHILD and WS_VISIBLE. I call SetParent()
and the dialog box shows itself nicely in the client area of its parent. So far so good.
But (in the WM_SIZE message code of its parent) when I try to resize the dialog box,
it just does not work. I can't change its size, not even get it smaller. Neither SetWindowPos nor MoveWindow worked.
Windows error says: "Invalid window handle" - I don't get it, the dialog box handle is fine.

Is there a way to overcome this?

Thanks.