在VB.net中创建和存储光标值 [英] Creating and storing cursor values in VB.net

查看:98
本文介绍了在VB.net中创建和存储光标值的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用LaptopTouchpad获取光标坐标.我需要在光标移动时跟踪所有坐标,并将它们存储在数组中以备将来参考.但是我只得到当前的坐标.我以为要跟踪坐标,我需要存储在数组中.在这样做的同时,我在数组的所有索引位置中仅获得当前坐标.

如果有人可以给我一个有效的示例代码,这将很有帮助.

I am using LaptopTouchpad to get cursor coordinates. I need to track all the coordinates while the cursor moving and store them in an array for future reference. But i am getting only present coordinates. i thought that to track coordinates, i need to store in an array. while doing that i am getting only present coordinates in all the index position of array.

It would be helpful if someone can give me a sample code that works.

推荐答案

您可能不会使用相同的代码这个.

没那么难.您可以在Form MouseMove事件中获取当前坐标,并将它们添加到List(Of Point)集合中.然后,您更改文本框以显示坐标.
You''re probably not going to same code for this.

It''s not that hard. You get the current coordinates in the Form MouseMove event and add them to a List(Of Point) collection. Then you change the textboxes to show the coordinates.


这篇关于在VB.net中创建和存储光标值的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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