The SnapToPanel VI enables you to position a Target VI window relative to a Reference VI window. Run the included example VIs to see how you can use this functionality in your applications to control the position of sub-panels relative to the main application panel.
Readme file for SnapToPanel VI
Description
The SnapToPanel VI enables you to position a Target VI window relative to a Reference VI window.
Use the SnapToPanel VI in your application to control the position of sub-panels relative to the main application panel.
Application Software
LabVIEW 7.x
Driver Software
None.
Description of Operation
The SnapToPanel VI positions a Target VI window relative to a Reference VI window by calculating the size and position of the Target and Reference VI windows. Then the VI uses this information to calculate the position to move the Target VI window to based on the setting of the "Snap to Position (Tile Right)" control.
Twenty-seven positions are available:
Window - Top Left Corner 0
Window - Top Left 1
Window - Top Center 2
Window - Top Right 3
Window - Top Right Corner 4
Window - Right Top 5
Window - Right Center 6
Window - Right Bottom 7
Window - Bottom Right Corner 8
Window - Bottom Right 9
Window - Bottom Center 10
Window - Bottom Left 11
Window - Bottom Left Corner 12
Window - Left Bottom 13
Window - Left Center 14
Window - Left Top 15
Panel - Top Left 16
Panel - Top Center 17
Panel - Top Right 18
Panel - Right Center 19
Panel - Bottom Right 20
Panel - Bottom Center 21
Panel - Bottom Left 22
Panel - Left Center 23
Panel – Center 24
Tile Left 25
Tile Right (Default) 26
Extracting the files
The SnapToPanel VI is supplied as a zip archive containing all required items. The zip archive contains full path information.
When extracting the items, set the path to C:\. Since the zip archive includes full path information, the included items will be extracted to the following path:
C:\Program Files\National Instruments\LabVIEW 7.0\user.lib
Extracting the items to the user.lib directory makes the SnapToPanel and usage example VIs available on the LabVIEW Functions palette.
Additional Information
Additional information related to the use and operation of the SnapToPanel VI may be accessed via:
- Execution of the usage example VIs
- The block diagrams of all included VIs
- The documentation within all included VIs
Developed by
Mark Ridgley
mark.ridgley@cardinalhealth.com
REQUIREMENTS:Application Software: LabVIEW Full Development System 7.0
Hey Mark. As always nice clean code with good comments.
Dick