2012-01-07 3 views
0

"데스크톱 창"을 기준으로 "대화 상자 창"좌표가 자체적으로 표시되는 것을 찾고 있습니까?바탕 화면에서 내 대화 상자 위치를 찾으려면 어떻게합니까?

다음 중 어느 것도 필요하지 않습니다. 는 데스크톱 윈도우의 크기가 0,0

HWND hWnd = ::GetDesktopWindow(); 
::GetClientRect(hWnd, &rectWin); 
c.Format("%d %d %d %d", rectWin.top, rectWin.bottom, rectWin.left, rectWin.right); 
MessageBox(c); 

답변

0

http://support.microsoft.com/kb/11570

에서 시작을 정의 대화 창의 크기가 0,0

HWND hWnd = ::GetForegroundWindow(); 
::GetClientRect(hWnd, &rectWin); 
c.Format("%d %d %d %d", rectWin.top, rectWin.bottom, rectWin.left, rectWin.right); 
MessageBox(c); 

에서 시작을 정의 0,0

에서 시작

관련 문제