[thelist] ASP question: the string is too long for the pulldown menu

Ken Kogler ken.kogler at curf.edu
Tue Feb 5 15:31:01 CST 2002


> I used "Left(rs("keyword"),80)" function
> to cut the string.  But I have a problem here:
> I don't want the last word to be cut in half.
> What I like is that the user should be able to
> see the complete last word such as "policy"
> instead of "poli".  I know I can search
> for the nearest space after position 80,
> but is there any other way to handle this?

You've got the right idea - look for the nearest space after 80. Come to
think of it... You may want to look for the first space *before* 80
instead (in case character 80 is the first "p" in
"pneumonoultramicroscopicsilicovolcanoconiosis" [1] or something equally
ridiculous that would destroy your table layout).

> How do you set the width of a pulldown menu? Can you?

Try researching CSS a bit. I'm not sure you can find a solution that
will work in all browsers, though.

-Ken

Ref:
1. http://members.aol.com/gulfhigh2/words11.html




More information about the thelist mailing list