1 bool GetScreenSize(UINT& unWidth, UINT& unHeight) 2 { 3 try 4 { 5 unWidth = ::GetSystemMetrics(SM_CXSCREEN); 6 unHeight = ::GetSystemMetrics(SM_CYSCREEN); 7 return true; 8 } 9 catch() 10 { 11 unWidth = 0; 12 unHeight = 0; 13 return false; 14 } 15 }
|