如何检测屏幕上特定位置的窗口/控件? [英] How to detect what window/control is at a specific point onscreen?

查看:222
本文介绍了如何检测屏幕上特定位置的窗口/控件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有Win32 API调用来确定在特定坐标和/或鼠标下可见的窗口和/或控件?

Is there a Win32 API call to determine what window and/or control is visible at a certain coordinates and/or under the mouse?

推荐答案

您可以使用

You can use GetWindowFromPoint. It will return the window handle so you can than use GetClassName function to see which control it is.

这是一个示例: http://support.microsoft.com/kb/112649

这篇关于如何检测屏幕上特定位置的窗口/控件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆