1. Video of Quick Drop in Action
This video demonstrates the use of Quick Drop to quickly find and place objects on the block diagram of a LabVIEW VI. Playback is at actual speed.
Finding the correct function or snippet of code can be challenging in any language. Text-based development environments depend on proper syntax, but many modern development environments help by automatically completing partially typed functions using predictive text.
Figure 1. NI LabWindows™/CVI software automatically generates a list of matching items for partially completed functions.
While the LabVIEW graphical development environment has always required a computer mouse to place and position objects, Quick Drop now helps you quickly navigate to the correct VI with a few simple keystrokes before placing the item with the mouse.
3. How Quick Drop Works
To begin using Quick Drop, press CTRL and Space. The dialog that appears contains a list of all the VIs in the palettes.
Figure 2. Press CTRL + Space to show the Quick Drop dialog.
You can filter the list by typing a phrase from the title of the VI you need. Quick Drop shortens the list as you type to display items with names containing your entered text. Quick Drop also applies predictive text to your query using the first VI in the palette that begins with the same letters.
In the Figure 3 example, the user has typed “t-r-a-n.” LabVIEW attempts to automatically predict the name of the object using the first matching entry. The filtered list shows candidates that contain “t-r-a-n” somewhere in the name.
Figure 3. Quick Drop automatically completes queries with the first VI that begins with the same letters and shows all other possible matches in the list.
Quick Drop automatically places the highlighted item on the mouse cursor so you can type the name of a function and click once on the block diagram or front panel to place the object. If Quick Drop cannot predict your search, you can select the correct item from the list of matching results.
4. Tips and Tricks for Using Quick Drop
Keyboard Shortcuts Accelerate Programming
Several new keyboard shortcuts have been added to Quick Drop in LabVIEW 2009 that speed programming even more. The first shortcut automatically generates all controls and indicators for a selected VI, eliminating the time it would have taken to place these objects. Select the VI then open Quick Drop (<ctrl + space>) and then press <ctrl + D>. Use <ctrl + shift + d> instead to automatically place all input constants for the selected VI.
Figure 4. Select a VI, then press <ctrl + space> to open Quick Drop. Once the window appears press <ctrl + D> to automatically place and wire all controls and indicators for the selected VI.
Removing an unwanted VI in an application often requires you to rewire all tunneling wires like errors or references. Save time by pressing <ctrl + R> after selecting a VI and opening Quick Drop to remove a VI and connect input and output wires in place of that VI.
Figure 5. Select a VI, then press <ctrl + space> to open Quick Drop. Once the window appears press <ctrl + R> to delete the selected VI and connect corresponding input and output wires.
Some LabVIEW programmers prefer their labels on the left of input and right of outputs, and changing those positions can take time. Automate the process by pressing <ctrl + T> with Quick Drop open to move labels from the top of controls, indicators, and constants on a selected VI to the sides.
Figure 6. Select a VI, then press <ctrl + space> to open Quick Drop. Once the window appears press <ctrl + T> move object labels from above to the sides of objects.
Create Your Own Keyboard Shortcuts
You can also configure shortcuts within Quick Drop to help access the VIs you use frequently without scrolling through results by clicking on the “Shortcuts” button from the Quick Drop dialog.
Figure 7. Click the “Shortcuts” button to define custom shortcuts for your most commonly used palette items.
You can make complicated VI names or VIs that share the first part of a name with other VIs more readily available by linking them to a two- or three-letter shortcut. It is recommended that you use letters that you can easily reach with your nondominant hand to keep your dominant hand on the mouse.
Figure 8. Try to define shortcuts using two or three letters.
LabVIEW stores your configured shortcuts in the LabVIEW.ini file. Copy and paste the value of QuickDropDiagramShortcuts and QuickDropPanelShortcuts into the LabVIEW.ini file to transfer them to another installation. Find an example list of shortcuts below or copy the key value from below:
- ad1 = increment
- cs = case structure
- evstr = event structure
- fs = for loop
- wat = wait
- ws = while loop
To add a set of common shortcuts, copy the following text into the LabVIEW.ini file:
QuickDropDiagramShortcuts="1dg:One Button Dialog;2dg:Two Button Dialog;3dg:Three Button Dialog.vi;ac:Array Constant;ad1:Increment;as:Array Size;ba:Build Array;bbn:Bundle By Name;bc:False Constant;bp:Build Path;car:Compound Arithmetic;cbr:Call By Reference Node;ccat:Concatenate Strings;cr:Close Reference;cs:Case Structure;cstr:Concatenate Strings;cv:Current VI's Path;dds:Diagram Disable Structure;dfa:Delete From Array;ea:Empty Array?;eq:Equal?;estr:Empty String/Path?;estrc:Empty String Constant;evstr:Event Structure;fs:For Loop;fss:Flat Sequence Structure;fstr:Format Into String;g0:Greater Than 0?;geq:Greater Or Equal?;geq0:Greater Or Equal To 0?;gr:Greater?;mp:Match Pattern;mul:Multiply;nan:Not A Number/Path/Refnum?;nc:Numeric Constant;ndx:Index Array;neq:Not Equal?;nes:In Place Element Structure;nv:Invoke Node;ovr:Open VI Reference;ras:Replace Array Subset;rn:Property Node;s1d:Search 1D Array;sav:Select a VI...;sb1:Decrement;sc:String Constant;se:Select;sp:Strip Path;sss:Search/Split String;tc:Tick Count (ms);tmsc:To More Specific Class;ubn:Unbundle By Name;vtd:Variant To Data;wat:Wait (ms);ws:While Loop;"
QuickDropPanelShortcuts="bool:Push Button;ei:Error In 3D.ctl;eo:Error Out 3D.ctl;led:Round LED;nc:Numeric Control;nnd:Numeric Indicator;sac:Select a Control...;scan:System Cancel Button;sctr:String Control;smc:System Multicolumn Listbox;snd:String Indicator;sok:System Button;syscan:System Cancel Button;systb:System Table;"
If you are a new developer, you still need palettes to find required functionality by drilling into the appropriate category. However, as you become more familiar with LabVIEW and function names, Quick Drop gives you the ability to place the desired VI without navigating palettes. This is valuable for improving productivity as the default palettes grow with installed modules and additional functionality.
6. Learn More about LabVIEW 2009
To learn more about new LabVIEW 2009 features, visit the LabVIEW 2009 portal at ni.com.
Download LabVIEW to use the latest features.
The mark LabWindows is used under a license from Microsoft Corporation. Windows is a registered trademark of Microsoft Corporation in the United States and other countries.