LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how can I simulate a mouse-click?

I want to click automatically in some field in an external application. I can launch the application and I can set the mouse position, but how do I generate a click. I tried calling the keybd function in user32.dll but it doesn't work.
My system is LabView 6.1 on a Win2000 Professional machine
Certified LabVIEW Developer (CLD)
0 Kudos
Message 1 of 7
(3,997 Views)
Check this site:

http://gtoolbox.yeah.net
George Zou
0 Kudos
Message 2 of 7
(3,996 Views)
Thanks for the effort, but it doesn't really help me because I use Labview 6.1.
Besides, I just want to know why it doesn't work with the keybd function in user32.dll though all the other inputs work (simulating keystrokes)
I know that in Win2000 it can be done with sendinput too, but I don't know how to configure the CIN.

Thanks again,
Manu.
Certified LabVIEW Developer (CLD)
0 Kudos
Message 3 of 7
(3,996 Views)
Manu,

I would look for a C example on MSDN that uses SendInput. That would be the best place to start.

Randy Hoskin
Applications Engineer
National Instruments
http://www.ni.com/ask
0 Kudos
Message 6 of 7
(3,996 Views)
Hi Manu

Take a look of Windows API Function Utilities (32-bit) for LabVIEW. It's useful for me to control windows.

http://zone.ni.com/devzone/explprog.nsf/6c163603265406328625682a006ed37d/ebf11dd1f0feaef3862566790072a983?OpenDocument

Bill.
0 Kudos
Message 4 of 7
(3,996 Views)
Yep, that's the llb I use, but with it it's not possible to simulate a mouseclick.
But in the meantime I found it. By calling the mouseevent function in user32.llb it works.

Anyway, thanks for the tip.
Certified LabVIEW Developer (CLD)
0 Kudos
Message 5 of 7
(3,996 Views)
Hi there, I am also trying to get the mouse event to work. But as yet I have had no luck. I am new to the WIN32API functions. I would greatly appreciate any help on the matter.

Even better, if someone could forward a VI in Labview 6.0.2.

Regards

Mike
0 Kudos
Message 7 of 7
(3,996 Views)