Limit number of visible elements in a Combo Box

Limit number of visible elements in a Combo Box

  
Hi.
I would like to know if it is possible to limit the number of visible elements in a combobox.
By default a combo box has 30 elements visible, i want to limit the number of visible elements. Is that possible ?
Regards
Rodrigo Henriques
Hi Rodrigo,

I would guess you could add an Extended Property to the Combo Box of Name size and make its Value equal to the number of rows you want displayed.

Cheers,


Miguel
Hi.
Thank you for the fast reply. However using size does not work, it simply creates a combobox with n elements on the page, similar to a ListBox. I need to have the same appearance as a normal combo box, and when selected only display 10 elements at a time within the "popup" that apears.
Don't know if that is even possible, however it would be a nice feature if it could be done.

Regards.
Rodrigo Henriques
Hi.
Normally I define a Site Property with the value (p.e. 10) and in the Query that populates the Combo I use the site property in MaxRecords.

In this case maybe you can swap the Combo for an autocomplete, it's better because all the options can be used.
Rodrigo Henriques wrote:
Hi.
Thank you for the fast reply. However using size does not work, it simply creates a combobox with n elements on the page, similar to a ListBox. I need to have the same appearance as a normal combo box, and when selected only display 10 elements at a time within the "popup" that apears.
Don't know if that is even possible, however it would be a nice feature if it could be done.

Regards.
Rodrigo Henriques
 
 Hi Rodrigo,

Check out the example at the bottom of this page:
http://www.webdeveloper.com/forum/showthread.php?226530-Controlling-number-of-displayed-items-in-dropdown-combo-box

It changes a bit the default behavior of the combobox (onmouseover event expands the list...), although you can control the nr of items (apparently, as I only tested it in Chrome...). You can probably change the trigger event to an onclick, so it's closer to the default behavior.

Another option is letting the browser calculate the nr of visible elements. :)

Cheers,
Paulo