Add following code to OnCreate function in MainFrm.cpp:
int CMainFrame::OnCreate(LPCREATESTRUCT lpCreateStruct)
{
CClientDC mDC(this) ;
int x = mDC.GetDeviceCaps(HORZRES);
int y = mDC.GetDeviceCaps(VERTRES);
this->SetWindowPos(NULL,0,0,x,y,NULL);
}
0 Comments