HMONITOR hMonitor;
MONITORINFO mi;
RECT rc;
// get the nearest monitor to the passed rect.
hMonitor = MonitorFromRect(&wRect, MONITOR_DEFAULTTONEAREST);
// get the work area or entire monitor rect.
mi.cbSize = sizeof(mi);
GetMonitorInfo(hMonitor, &mi);
...
...