NO

Author Topic: Resizing Controls at run-time?  (Read 3765 times)

halsten

  • Guest
Resizing Controls at run-time?
« on: November 18, 2008, 08:19:30 PM »
My question is simple, I want to know how to resize the control according to the current width and height of the form during run-time, any sample(s) would be highly appreciated.

Regards,
halsten

CLR

  • Guest
Re: Resizing Controls at run-time?
« Reply #1 on: November 18, 2008, 11:49:24 PM »

iancasey

  • Guest
Re: Resizing Controls at run-time?
« Reply #2 on: April 26, 2009, 10:33:15 PM »
This is late but maybe others can use it.

it was originally written in BCX but here is the "c" translation of my demo.

http://www.bcxgurus.com/bcxusers/Ian/Chat_Files/AnchorDemo.C

sorry if there alot of test controls in there.

Ian

Offline TimoVJL

  • Global Moderator
  • Member
  • *****
  • Posts: 2091
Re: Resizing Controls at run-time?
« Reply #3 on: April 27, 2009, 06:49:46 PM »

In WndProc:
Code: [Select]
case WM_SIZE:
MoveWindow(hWndEdit, 0, 0, LOWORD(lParam), HIWORD(lParam), TRUE);
return 0;
May the source be with you