Sending Messages to child windows

I'm trying to send a message from the parent window to the child window that makes the child resize when the parent does. I get an unhandled exception when I try this. Any suggestions?
This was my first atempt at sending a message between windows, so I don't know what I did wrong.
	case WM_SIZE:
		SendMessage(hWnd, WM_SIZE, wParam, lParam); 
		return 0;
//hWnd is the child window's handle, the rest are all the same info
//that the parent receives when resized. 
Sending WM_SIZE won't work. Use MoveWindow(). That takes the same sizing parameters as the x,y,cx,cy parameters of CreateWindow().
Topic archived. No new replies allowed.