I've multiple select box with specific predefined width. So all the boxes look similar in width on a form. But, if text within it is longer than width , can we show something like toolTip on Mouseover of that option.
Thanking you all in advance..
07-04-2002, 04:18 PM
Mozilla automatically makes scrollbars,so you can do something like this for IE:
Thak u bosko for ur reply, but i want 2 show the tooltop on Mouse Over that is b4 selecting the option.
please tell me is there anything similar to onMouseOver event in multiple select box?
07-05-2002, 04:31 PM
If you set the title attribute you get a tooltip right away,which changes when the user selects something.
If I have written code as :-
<Select name="selName" style="width: 50">
<OPTION value="">Ball Valve </OPTION>
<OPTION value="">Butterfly Valve </OPTION>
in the browser, in select box it displays Ball Valve in full as written but when some text woth longer length , it cuts it off.
as Butterfly Valve gets only displayed as -- Butterfly v
so , on page display itself....(not any , onChane,, event but onMouseOver..) , i want to show all texts with longer length as ToolTip...
07-27-2002, 05:46 AM
It seems you are looking for the same thing I am...that is a "mouseover within a select option" This is the only way to solve my problem (if it is possible at all!) But for you, simply making the length of the drop box as long as your longest entry will prevent text from being lost (although shorter enties will fill with spaces).
07-27-2002, 05:52 PM
The option tag does not support any events. you cannot do any dynamic effects from the mouse events. The closest you can come it to uses a mouse move event and use the position of the mouse to determine which option you are over.
Not impossible, but you will never get it to handle more than one resolution, and cross-browser will be a nightmare. Good luck.
07-27-2002, 06:39 PM
Originally posted by COBOLdinosaur
The option tag does not support any events. you cannot do any dynamic effects from the mouse events.
That's only true with IE and legacy browsers - gecko can do <option onmouseover
07-27-2002, 11:21 PM
The fringe browsers can do a lot of neat stuff, but it does not help as long as the overwhelming majority of users continue to use IE.
07-29-2002, 04:45 AM
I was coming to this conclusion myself and had already considered and dismissed the "mousemove" idea as impossible to determine the mouse co-ordinates (especially when the co-ord's would be identical for each option once the box starts to scoll).
As an alternative, I was hoping someone may have built a custom "drop down box" in java that would have a "mouseover option" capability. (it would need to scroll...those I've seen can't) I don't know if this is possible (not knowing anything about Java other than plugging in and configuring an applet.) Anyone with java knowhow who can do this? You woud have a very popular applet.
The idea seems so simple that I don't know why "onmouseover option event" wasn't incorporated in the orignal contruction of the combo-box control.
Corel Draw actually has this in its "select font" dialog. Mousing over an option in the "select font" drop down box displays a graphic sample of the font. (granted this isn't DHTM or java)
" There's nothing that's been done that can't be done"