如何获得鼠标点击位置 [英] How to get mouse click position
本文介绍了如何获得鼠标点击位置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如您所知,无论何时在我的应用程序上以及其他应用程序窗体上,我都希望获得鼠标单击的位置.
有人有想法吗?我是C#的新手,有人会给我一些建议或示例吗?
非常感谢.
As you know, I want to get the mouse click position when ever I click the mouse, not only on my application, but also on other applications forms.
Does anyone have ideas? I am a new guy of C#, would some one give me some advice or some samples?
Thanks very much.
推荐答案
这应该可以帮助您:
鼠标坐标 [ ^ ]
This should help you out:
Mouse coordinates[^]
使用WinApi,您可以如下所示进行操作:
Using WinApi, you can do this as shown here.
这篇关于如何获得鼠标点击位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文