Example Code

Programmatically Detect Front Panel Indicators

Code and Documents

Attachment

Introduction:

If you need a way to programmatically detect and list all controls and indicators on a VI front panel, this can be done through the use of property nodes.  This example detects all indicators on the front panel, places them in an array, and writes the indicator names on a front panel Array Indicator.

This example is based on this NI Discussion Forum post:

http://forums.ni.com/t5/LabVIEW/distinguishing-between-indicator-and-controls-using-property/td-p/12...

Instructions:

1. Place any control or indicator on the front panel.

2. Run the VI.  Notice the array being build in the case structure for indicators.  If you would like to also detect controls, you could set up a separate array for the False case (when the front panel item is not an indicator).


Software:

LabVIEW 2011

DetectIndicators.png

Regards,
Austin S.

National Instruments
Academic Field Engineer

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Comments
pbuerki
Member
Member
on

The link appears to be broken

Austin_S
NI Employee (retired)
on

Thanks for catching that.  The thread was moved and I've updated the link.

Regards,
Austin S.

National Instruments
Academic Field Engineer
Contributors