LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to make vertical scrollbar visible for listbox which shows one entry only?

I have resized listBox to display only one entry of char* items. As there is only one item displayed vertical scrollbar is not visible. Is there a way to show the scrollbar when listbox display is sized to show only one item?

Using up/down arrow it does scroll through other entries.

*************************************************
CLD
*************************************************
0 Kudos
Message 1 of 13
(5,909 Views)

Sorry the last line where I said that the up/down arrow helps scroll through the items is not true as listbox is a indicator and not control.So currently there is not way to scroll through the listbox.

*************************************************
CLD
*************************************************
0 Kudos
Message 2 of 13
(5,909 Views)

If your listbox is an indicator, you would not be able to use scrollbars... So what is the purpose of scrollbars?

0 Kudos
Message 3 of 13
(5,901 Views)

You can always make your own scroll buttons.

 

Just add two picture buttons next to your listbox and put some arrow icons on them.

All you need to do is get the current selected index, increment/decrement it and set it back.

S. Eren BALCI
IMESTEK
0 Kudos
Message 4 of 13
(5,897 Views)

// PLEASE REMOVE

S. Eren BALCI
IMESTEK
0 Kudos
Message 5 of 13
(5,896 Views)

lvrat:

 

If you want to display only one item but give the operator the ability to scroll through other items, you might do better using a Ring instead of a Listbox.  Leave it as a control (e.g. Hot or Normal) and not an Indicator, or you'll lose the scrollbar-like increment/decrement arrows.  You have as much control in your code over a Control as you do an Indicator: you can still set the value and control what is displayed.

0 Kudos
Message 6 of 13
(5,883 Views)

 

The only problem using ring instead of listbox is that when there is a lot of items it pulls down the ring and hids all the other GUI items behind it. 

Real estate was one reason of using list box and displaying one value. I did change the list box as a control instead of indicator but still cant get the scrollbar funcitonality.

 

ANy other suggestion, thanks!

*************************************************
CLD
*************************************************
0 Kudos
Message 7 of 13
(5,872 Views)

The reason is your choice of one line only.

 

What is still possible even for one visible line is operating the listbox with the up and down arrows of your keyboard.

0 Kudos
Message 8 of 13
(5,869 Views)

see also here

0 Kudos
Message 9 of 13
(5,855 Views)

Hi dear all.

I would like to know how can i make listbox wich elements are combobox or enum variables? If sombody has alredy dan that please send me example or code.

 

thenks a lot

0 Kudos
Message 10 of 13
(5,842 Views)