If you had the coordinates of a certain widow, how would you get the handle?
This is a discussion on Finding window with coordinates within the Windows Programming forums, part of the Platform Specific Boards category; If you had the coordinates of a certain widow, how would you get the handle?...
If you had the coordinates of a certain widow, how would you get the handle?
Gays can't love like real people
entropysink.com -- because arses weren't designed for running websites.
By getting the handles for all windows and checking whether the co-ordinates match for each one in turn??
I thought of that, but I was just wondering if there was an easier approach. Oh well, guess that's good enough
Thanks anyways.
Gays can't love like real people
entropysink.com -- because arses weren't designed for running websites.
Would 'WindowFromPoint' be what you are after?:
POINT pt; //set to coords eg mouse coord
HWND hWnd=WindowFromPoint(&pt);
There's also a fn 'ChildWindowFromPoint' that may also be of interest.
Now THAT's what I'm talkin' 'bout. Thanks a heap, ken.
Gays can't love like real people
entropysink.com -- because arses weren't designed for running websites.