Can I Programmatically Set the "Element Gap" Property?

Updated Aug 24, 2023

Reported In

Software

  • LabVIEW

Issue Details

I want to adjust the spacing between elements of an array control shown in the front panel. When editing a VI, I could do this through the Add Element Gap or Remove Element Gap menu by right-clicking the array. However, I would like to change this property during application runtime. 

Solution

Unfortunately, you cannot change that property in run-time. In LabVIEW, you can programmatically change the properties of controls and indicators through the property node. However, this does not mean all properties can be changed at the runtime. Some properties can only be read-only or only settable during editing. You can find this information by searching the property name in the LabVIEW Help. For example, Element Gap? property has the characteristics in which Permissions is read/write and Settable when the VI is running is No. This means that you can only set the property in the edit time. 

Additional Information

Some properties or methods can only be displayed or set by enabling the VI Script option. Please refer to the following link for this. 
LabVIEW Help: Enabling VI Scripting