Programatically Highlight an Item on a Tree Control

Updated Apr 1, 2021

Issue Details

How can I programatically highligth an item in a Tree control?


The value of a tree control is the tag that is currently selected, so setting the Value to the appropriate tree tag will highlight that item. The following steps outline the process for creating this property node: 

1. Right-click the Tree control and select Create » Property Node » Value.
2. Right-click the Property Node and select Change to Write from the shortcut menu.
3. Right-click the Property Node and select Create » Constant from the shortcut menu.
4. In the string constant that appears, enter the name of the tag that you want to highligth.

See the LabVIEW snippet below.