Link to home
Start Free TrialLog in
Avatar of luotuo
luotuo

asked on

combo box

When combo boxes are set using 'width:300px', they all look tidy, but when they are populated with data of different length, some data gets cut short in drop-down. However, without the width setting, combo boxes get expanded and out of control when the data populated. What can I do to keep them look tidy but all the data can be shown in drop-down.
Avatar of dorward
dorward

There is no such thing as a combobox in HTML. I suspect you mean a select element, which is often rendered as a drop down list (a combobox is a dropdown list combined with a text box so the user can pick an option or type their own).

The only solution is to avoid excessivly long option labels.

You could also consider switching from a select element to a series of radio buttons. Radio buttons are more flexible when it comes to layout.
Avatar of luotuo

ASKER

Thanks.

Well, I cannot really do that as there are 6 drop-down lists on my jsp web page, and each of them is populated with data from database, and each of them may hold about more than 10 records.  Is there some sort of horizontal scrollbar to those drop down lists?
ASKER CERTIFIED SOLUTION
Avatar of dorward
dorward

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of luotuo

ASKER

I doubt it too. But will give it a go anyway.

Thank you very much!
Avatar of luotuo

ASKER

Would you pls change my grade to this question to A. It page processed before I could change my choice.

Thanks.

https://www.experts-exchange.com/questions/20823847/combo-box.html#9926820