LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to hide a List Box.

Solved!
Go to solution

Hi.

 

Is it possible to hide a List Box?

For example I want five overlapping List Boxes and five control buttons, one associated with each list box. When a button is pressed the associated list box should then be made visible.

I could not find  a SetCtrlAttribute (panelHandle, PANEL_LISTBOX1, ATTR_HIDE_ACTIVE_ITEM, 0) type command to hide a list box.

 

How can this be accomplished?

 

Thanks.

0 Kudos
Message 1 of 4
(3,281 Views)

I think all you need is ATTR_VISIBLE:

 

SetCtrlAttribute (panelHandle, PANEL_LISTBOX1, ATTR_VISIBLE, 1);

 

--Ian

Message 2 of 4
(3,279 Views)
Solution
Accepted by topic author NI Nubie

That was it. Silly me,  I was searching for Hide, Hidden ... not Visible.

 

Thanks.

0 Kudos
Message 3 of 4
(3,275 Views)

A possible alternative solution is to use a tab control, with a listbox on every tab panel: only one tab page is visible at a time and you can switch from one to the other simply clickong the desired page to see.

Moreover, you can design the tab control with one tab page only, duplicating it at runtime for the number of desired paged so have in your application: designing the user interface will be greatly simplified.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 4 of 4
(3,260 Views)