[MFC] Set size "main" window

I started to create a project based on CScrollView MFC class. Unfortunately I can not resize the main window.

I tried to change the parameters of CREATESTRUCT, but I got no change.

1
2
3
4
5
6
7
8
9
10
BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
{
	if( !CFrameWndEx::PreCreateWindow(cs) )
		return FALSE;

	cs.style &= ~FWS_ADDTOTITLE;
	cs.cx = cs.cy = 400;  //doesn't work!
	
	return TRUE;
}



How can I really set the size of my application?

Thanks...
Set the size before you call ShowWindow().
Topic archived. No new replies allowed.