Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Horizontal Scroll Bar for listbox

Reply
Thread Tools

Horizontal Scroll Bar for listbox

 
 
Lloyd Sheen
Guest
Posts: n/a
 
      10-31-2003
I have searched wide and far through google for a solution to no avail. Is
there a method available to add a horizontal scroll bar to a listbox in
asp.net.

Thanks in advance


 
Reply With Quote
 
 
 
 
Nicole Calinoiu
Guest
Posts: n/a
 
      11-01-2003
Lloyd,

It's not directly possible. This has nothing to do with ASP.NET. Rather,
it is a limitation of the HTML select element (which is how the ASP.NET
listbox is rendered in the browser). One workaround would be to wrap your
wide listbox in a div or span of the desired width, then set the wrapper
element to use a scrollbar on horizontal overflow. e.g.:

<div style="width:80px; overflow-x:auto">
<asp:ListBox id=YourListBox runat="server"></asp:ListBox>
</div>

HTH,
Nicole


"Lloyd Sheen" <(E-Mail Removed)> wrote in message
newsuCob.80149$(E-Mail Removed) le.rogers.com...
> I have searched wide and far through google for a solution to no avail.

Is
> there a method available to add a horizontal scroll bar to a listbox in
> asp.net.
>
> Thanks in advance
>
>



 
Reply With Quote
 
 
 
 
Andrew de la Harpe
Guest
Posts: n/a
 
      11-01-2003
A listbox is just a SELECT element.
If you need horizontal scrolling, wrap the listbox with a DIV or SPAN.
A

"Lloyd Sheen" <(E-Mail Removed)> wrote in message
newsuCob.80149$(E-Mail Removed) le.rogers.com...
> I have searched wide and far through google for a solution to no avail.

Is
> there a method available to add a horizontal scroll bar to a listbox in
> asp.net.
>
> Thanks in advance
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Add horizontal Scroll bar to a Server Control Listbox or DropDownL =?Utf-8?B?VmlkZHM=?= ASP .Net 3 11-23-2005 08:00 PM
XVT ListBox- Horizontal scroll Programmer C++ 1 10-25-2005 06:54 PM
Listbox horizontal scroll André Nobre ASP .Net 4 07-13-2005 04:49 PM
listbox horizontal scroll? Tina ASP .Net 2 10-02-2004 12:52 AM
horizontal scrollbar in a div causing another scroll bar to more. Jeremy Chapman ASP .Net 1 08-15-2003 10:01 PM



Advertisments