LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

how to extract information in cells of a mult-column list box?

I have multi column list box. At run time this listbox allow me to select entire row (this is fine), how to extract the data from each cell along the selected row? It seems to me that the Multi column Listbox (MCL) is merely a 1D array (I guess index of this 1D array corresponds to row index of the MCL and value of the element corresponds to column index of MCL.)
0 Kudos
Message 1 of 5
(2,117 Views)
You need to create a property node for the listbox and select "Item Names". That gives you a 2D array of string for each of the elements. Use the terminal for the listbox to index your 2D array. If you are using a selection mode that allows more than 1 selection, the terminal data type will be a 1D array. Each element in that array is a row index into the 2D array of Item Names.

Daniel L. Press
PrimeTest Corp.
www.primetest.com
Message 2 of 5
(2,117 Views)
Proton,
Thank you for your feedback.
0 Kudos
Message 4 of 5
(2,117 Views)
To extract cell values of the selected row, you can create a property node for the MCL. From this property node, choose "Item Names". This is a 2D array containing all cell values. Index this array with the MCL terminal. Note that you must choose the scalar data type for the MCL. To choose the scalar data type, right click on the MCL and go to "Selection Mode"->"Data Type"->"Scalar".

See attachment written with LabVIEW 6.

I hope it will help you.
Message 3 of 5
(2,117 Views)
Csch,
Thanks, I got it.
0 Kudos
Message 5 of 5
(2,117 Views)