...

View Full Version : Want scrollbar to appear after 5 items are displayed



Reina
11-18-2002, 01:46 AM
Hello,

How can you specify the maximum number of items to be displayed in a combo box before a scrollbar appears?. IE has a default of 8 items but Netscape 4.x displays around 20 items before the scrollbar appears. I would like the scrollbar to appear when more than 5 items are displayed. I am using CSS to style my form elements.

Any ideas??

Thanks,
Reina

zoobie
11-18-2002, 06:08 AM
You've tried size:5; in css or size="5" in html?

Reina
11-19-2002, 12:28 AM
Hello...

To clarify.... when you click on the drop down arrow of the combo box, it would be great if the drop-down list area size could be set to 5 items long. The user can then just use the scrollbar to scroll through the rest of the items on the list.

Thanks for the help,
Reina

JustAsking
11-19-2002, 12:37 AM
Reina,

I had a look and get what you are trying to do. When I tested using IE6.0 the scrollbar appeared when I had more than 11 items in the dropdown box. When viewing in NN6.2 the scrollbars didn't appear until there were 22 items in the dropdown box. As for your question, how to make it appear with 5 or more, if can't see that could be changed. :cool:

zoobie
11-19-2002, 01:16 AM
Originally posted by zoobie
You've tried size:5; in css or size="5" in html?
:rolleyes:

JustAsking
11-19-2002, 02:35 AM
zoobie,

I don't think that is what he is after.

My understanding is to keep the dropdown as size="1", but when you open the dropdown box a scrollbar will appear once there are 6 or more items.

Is that your understanding :rolleyes:

Reina
11-19-2002, 04:47 AM
JustAsking, yes that's exactly what I'm trying to get at. You may be right about not being able to set when the scrollbar appears....

Thank you zoobie and JustAsking for your input.

Nix
03-04-2004, 10:10 AM
Is there really no way to do that?
cause i need the solution too...

me'
03-04-2004, 07:15 PM
Why, may I ask? You should technically just provide the data. The browser decides how it wants to interpret it. For the same reason as for why you shouldn't change the scrollbar colour (http://www.codingforums.com/showthread.php?s=&threadid=31231), I see no reason why you need to limit the height of a combobox.

jdan
03-05-2004, 12:05 PM
Originally posted by me'
Why, may I ask? You should technically just provide the data. The browser decides how it wants to interpret it. For the same reason as for why you shouldn't change the scrollbar colour (http://www.codingforums.com/showthread.php?s=&threadid=31231), I see no reason why you need to limit the height of a combobox.

Hrmm, doesn't seem quite right to me. The page could require that height of the combobox for the aesthetics to come out as the designer wants. Assuming the size altering doesn't hinder functionality of the page I'm all for screwing the design up to your hearts extent. Can't always stick to the applications basic design, fight the machine..! :)

tzuuyi
01-25-2007, 04:17 PM
Hi, it's 2007 now, 5 years from when the question began. Is there any new information? I found JAVA can set the items in a dropdown box before scroll bar appears but I cannot find any information on html.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum