The WindowEx.WindowFromPoint function retrieves the handle of the window that contains the specified point.
number WindowEx.WindowFromPoint(
number XCoord --X Coordinate Of The Point
number YCoord --Y Coordinate Of The Point.
);
Parameters
XCoord
Specifies X Coordinate Of The Point
YCoord
Specifies Y Coordinate Of The Point
Return Values
If the function succeeds, the return value is the handle of the window that contains the point. If no window exists at the given point, the return value is 0.
Remarks
The WindowEx.WindowFromPoint function does not retrieve the handle of a hidden or disabled window, even if the point is within the window. An application should use the WindowEx.ChildWindowFromPoint function for a nonrestrictive search.