03-27-2014 11:56 AM
If you still want to do this, use the mouse input VIs instead of the mouse move event. This will require polling, but will give you global coords.
If you want to minimize the polling, you could do this by reading the mouse down event, setting the timeout to N, doing the movement code in the timeout event and using Mouse Up to reset the timeout to -1. You might have to start by getting the offset of the mouse relative to the panel (the pane and panel classes should have conversions method, which you could probably use directly in your current code, but I expect it would still be choppy).
03-27-2014 12:15 PM
Yes, I still want to do this.. I wish to remain undefeated by LabVIEW 🙂 I'll try your suggestions.
Thanks,
03-28-2014 05:38 AM
Hi Christopher,
Tst is correct (of course). Using the Mouse Move Event won't work very well.
1) You get tons of events
2) The values are buggy in my opinion
I captured the data from the Mouse Move Event and found that the values occasionally "back up" when moving in a constant direction. This does not seem correct.
Attached is an LabVIEW 2012 implementation using polling in the Timeout Event.
The Timeout value is set in the Mouse Down Event - this sets the sensitivity.
steve
03-28-2014 06:26 AM
Awesome, thank you! That works much more smoothly.
04-10-2018 10:23 AM
Thanks for sharing this. IT was really interesting to find a solution for this following your method.
05-29-2018 11:51 AM
It works only if you move your cursor relatively slow. With dynamic use it does not work.
05-30-2018 04:51 AM
@bienieck wrote:
It works only if you move your cursor relatively slow. With dynamic use it does not work.
Did you try reducing the "TO" value in the "Pane": Mouse Down event?
You could change the TO constant to a control to make it easier to experiment.
steve