~cpp
BOOL CMainFrame::PreCreateWindow(CREATESTRUCT& cs)
{
if( !CFrameWnd::PreCreateWindow(cs) )
return FALSE;
// TODO: Modify the Window class or styles here by modifying
// the CREATESTRUCT cs
cs.cx = 300;
cs.cy = 600;
cs.x = ::GetSystemMetrics(SM_CXSCREEN)-300;
cs.y = 0;
return TRUE;
}