C++ MDI应用启动时子窗口默认最大化

1 新建MDI应用程序

2 修改CChildFrame的成员函数PreCreateWindow() 


BOOL CChildFrame::PreCreateWindow(CREATESTRUCT& cs)
{
	// TODO: 在此处通过修改 CREATESTRUCT cs 来修改窗口类或样式
	if( !CMDIChildWnd::PreCreateWindow(cs) )
		return FALSE;

	cs.style = cs.style | WS_MAXIMIZE | WS_VISIBLE;

	return TRUE;
}

猜你喜欢

转载自blog.csdn.net/dxm809/article/details/113822533