Overview
To Demonstrate How Hotkeying and Key Navigating using Key Presses to Control Front Panel
Description:
This example uses two methods of hotkeying: the Key Down event structure case and Key Navigation, and compares and contrasts the functionality of both.
Key Navigation is much easier to set up and use, requiring no wiring to do basic operations on controls, such as pressing a button. These options are accessed by right-clicking on your control, and mousing down to Advanced, then clicking Key Navigation. However, only certain keys may be used. Key Navigation may be masked by using property nodes, but this detracts from their ease of use.
Using an event structure, however, is more versatile, but has its own complications. For instance, you can use any key to perform any function, and you can mask events based on certain conditions (for instance, to mask the events when you are focused in a string control, so that you don't trigger anything while typing, which is done in this case). However, it does require an event structure and additional wiring, which may be difficult, especially if you have other event-driven elements in your program.
The KnowledgeBase contains another hotkeying method, with the article found here:
http://digital.ni.com/public.nsf/allkb/F28692BC75DF51EE862572C0000897D5
Instructions:
To implement this example:
- Run the VI
- Refer the label of the control to find out what they do to the front panel
- (Optional) Turn on the Highlight Execution to see the flow of the VI
To execute this example:
- Install the required software.
- Open the VI and refer the Implement Steps
Requirements
Software
LabVIEW 2012 or compatible
Hardware
-
**This document has been updated to meet the current required format for the NI Code Exchange.**