15,980
社区成员
发帖
与我相关
我的任务
分享
HDC hdcScreen = GetDC( NULL );
int cx = GetDeviceCaps( hdcScreen, HORZRES );
int cy = GetDeviceCaps( hdcScreen, VERTRES );
DeleteObject( hdcScreen );
其中nIndex可以取: HORZRES VERTRES 或 分别表示: HORZRES :Width, in pixels, of the screen. VERTRES :Height, in raster lines, of the screen.