Word-wrap in DropDownList

L

Larry

Hi I have to use DropDownList to display some long names and I have
limited horizontal space. When I assign specific width to this
DropDownList, I cannot see whole text, only first few letters
(depending of course on given width). Is there any way to wrap words
in DropDownList? On MSDN site they say that "select" and "option"
objects (which are used by .NET to build DropDownList in HTML) use
"word-wrap" property, but it doesn't work (i have IE 6.0).
 
K

Ken Cox [Microsoft MVP]

Hi Larry,

I don't have a workaround for you but just to let you know that from what I've
seen so far, I have to agree with you that it doesn't work as described in the
documentation.

It just seems to chop the text rather than wrap.

Here's what I was trying:

DropDownList1.Attributes.Add("STYLE", "word-wrap:break-word;left:0")

Ken
MVP [ASP.NET]



Hi I have to use DropDownList to display some long names and I have
limited horizontal space. When I assign specific width to this
DropDownList, I cannot see whole text, only first few letters
(depending of course on given width). Is there any way to wrap words
in DropDownList? On MSDN site they say that "select" and "option"
objects (which are used by .NET to build DropDownList in HTML) use
"word-wrap" property, but it doesn't work (i have IE 6.0).
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,763
Messages
2,569,562
Members
45,038
Latest member
OrderProperKetocapsules

Latest Threads

Top