LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
0 Kudos
Julianne_K

Add Maximum Rows Property Node for Tree Control That Represents Actual Rows with Data (Does Not Include Partial Data)

Status: Declined

Any idea that has not received any kudos within a year after posting will be automatically declined. 

When using the Number of Rows property of a tree control, as shown below, the number of row returned does not reflect the number of rows with actual data. As you can see in Front Panel screenshot, the tree control has only 3 rows of data, but the property node indicates that there are 12 rows. This is because in the Properties window for the tree control, the number of rows is set the 12. The Number of Rows Property Node help file indicates that this property counts "partial rows" which means this property node is used correctly. However, it would be useful to have a property node which displays the rows with data.

 

For example, I was trying to implement a function to move a tree index down in the tree control. I wanted to implement functionality so that when the current row + 1 was greater than the maximum number of rows, set the new row to 0. However, since the maximum rows property is 12, not 3, in the below screenshot, the program would throw an error with this logic.  

 

RowProblem2.PNG

RowProblem.PNG

Julianne K
Systems Engineer, Embedded Systems
Certified LabVIEW Architect, Certified LabVIEW Embedded Systems Developer
National Instruments
2 Comments
tst
Knight of NI Knight of NI
Knight of NI

That property refers to the size of the control itself, not to its content.

 

There are other properties which refer to the content, such as All Tags and Displayed Items (which is probably the one you want), but you might still need to play around with it to get what you want.


___________________
Try to take over the world!
Darren
Proven Zealot
Status changed to: Declined

Any idea that has not received any kudos within a year after posting will be automatically declined.