LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Pointer Slider Control

 I was wondering if it is possible to assign keys to the Pointer Slider. For example, I am able to assign 2 keys ( CURSOR LEFT and CURSOR RIGHT) to a slider and I control it by clicking left and right and the pointer will move side to side. The gauge will move the same way. If the pointer slider is vertical, the gauge won't move. Here's a picture that i would like it to do:Capture.PNG

0 Kudos
Message 1 of 5
(3,159 Views)

You can use "Key Navigation" to define interaction with your front panel element. But this does not provide access "to any key" like e.g. up- or down-key.

So if you want to use those, you have to implement some code (using event structure) doing so.

 

Norbert

 

Norbert
----------------------------------------------------------------------------------------------------
CEO: What exactly is stopping us from doing this?
Expert: Geometry
Marketing Manager: Just ignore it.
0 Kudos
Message 2 of 5
(3,144 Views)

Sorry but is there an example that I can work on ?

0 Kudos
Message 3 of 5
(3,116 Views)

Go to Help >> Find Examples.. Then search for Events.  Look at Event Tracking.vi.

 

Inside the Type Into Me: Key Down? case expand the Event Data Node to get VKey or ScanCode.  Those will allow you to identify the arrow keys. In this example you need to give the string control focus before the event structure will capture the keys.

 

Lynn

0 Kudos
Message 4 of 5
(3,113 Views)

Also, you can Add a VI KeyDown? event that will work anywhere on the front panel.

 

Lynn

0 Kudos
Message 5 of 5
(3,111 Views)