| Forums.Sureshkumar.net : A Perfect Place to Share Knowledge Blogs Games Magazines |
|
|||||||
![]() |
|
|
LinkBack | Thread Tools | Rate Thread | Display Modes |
|
|
#1 (permalink) |
|
Member
Join Date: Apr 2007
Location: Right now in Chennai
Posts: 30
Thanks: 5 Thanked 5 Times in 3 Posts Thanks: 5
Thanked 5 Times in 3 Posts
Rep Power: 2
|
how to display tooltip for each item in multiselect box
Hi,
We have very long description for each field in multi select box., the box is not wide enough to see the full description. Is there any way to display a tooltip message when I put my mouse over the field. thanx in advance... Regards Ananth |
|
|
|
|
|
#2 (permalink) |
|
Super Moderator
Join Date: Feb 2006
Location: Hyderabad
Posts: 2,355
Thanks: 117 Thanked 241 Times in 198 Posts Thanks: 117
Thanked 241 Times in 198 Posts
Blog Entries: 4
Rep Power: 51
|
Re: how to display tooltip for each item in multiselect box
which Java technology you are using? is it desktop application or web based application?
__________________
Give 1 cup rice to a hungry Indian just by a mouse click. No money, no form filling, no hassle... Click here for the donation. |
|
|
|
|
|
#3 (permalink) |
|
Member
Join Date: Apr 2007
Location: Right now in Chennai
Posts: 30
Thanks: 5 Thanked 5 Times in 3 Posts Thanks: 5
Thanked 5 Times in 3 Posts
Rep Power: 2
|
Re: how to display tooltip for each item in multiselect box
hi kireeti,
this is the web based application and i am using struts. regards, Ananth |
|
|
|
|
|
#4 (permalink) |
|
Super Moderator
Join Date: Feb 2006
Location: Hyderabad
Posts: 2,355
Thanks: 117 Thanked 241 Times in 198 Posts Thanks: 117
Thanked 241 Times in 198 Posts
Blog Entries: 4
Rep Power: 51
|
Re: how to display tooltip for each item in multiselect box
You can try out overlib free javascript to do it along with onMouseOver and onMouseOut evens for option tags...
If you can't figure out how to use overlib javascript code.... let me know, I will provide a simple code for you which is very simple but with limited functionality.... Thanks, Krishna
__________________
Give 1 cup rice to a hungry Indian just by a mouse click. No money, no form filling, no hassle... Click here for the donation. |
|
|
|
|
|
#5 (permalink) |
|
Member
Join Date: Apr 2007
Location: Right now in Chennai
Posts: 30
Thanks: 5 Thanked 5 Times in 3 Posts Thanks: 5
Thanked 5 Times in 3 Posts
Rep Power: 2
|
Re: how to display tooltip for each item in multiselect box
Hi kireeti,
i tried overlib.js, but the thing is option tag not responding for onmouseover event or other events. it is working fine for other elements. Thanks & Regards, Ananth |
|
|
|
|
|
#6 (permalink) |
|
Super Moderator
Join Date: Feb 2006
Location: Hyderabad
Posts: 2,355
Thanks: 117 Thanked 241 Times in 198 Posts Thanks: 117
Thanked 241 Times in 198 Posts
Blog Entries: 4
Rep Power: 51
|
Re: how to display tooltip for each item in multiselect box
Ananth,
hmm... I am seeing that this is not supported IE. But Firefox (Netscape should also support) supports this event. Looking around for solution. But right now I can give you a work around which I have developed for my project.... Download attachment and follow instructions NOTE - 1. Rename the file to .html 2. Open the page in firefox or netscape 3. enter some text in filter criteria box and clear it to see complete list of values in select box (it is just a piece of sample code and this behavior is a bug!!!! don't mind) 4. Now change your selection in first select box.... related description will be shown in the below place provided. 5. Just place your mouse over an option in select list box... it displays a tool tip automatically (uses an attribute called "title" in options... doesn't work in IE) Thanks, Krishna
__________________
Give 1 cup rice to a hungry Indian just by a mouse click. No money, no form filling, no hassle... Click here for the donation. |
|
|
|
|
|
#7 (permalink) |
|
Super Moderator
Join Date: Feb 2006
Location: Hyderabad
Posts: 2,355
Thanks: 117 Thanked 241 Times in 198 Posts Thanks: 117
Thanked 241 Times in 198 Posts
Blog Entries: 4
Rep Power: 51
|
Re: how to display tooltip for each item in multiselect box
Some more info on MS specific events can be found here...
Welcome to the MSDN Library
__________________
Give 1 cup rice to a hungry Indian just by a mouse click. No money, no form filling, no hassle... Click here for the donation. |
|
|
|
|
|
#8 (permalink) |
|
Member
Join Date: Apr 2007
Location: Right now in Chennai
Posts: 30
Thanks: 5 Thanked 5 Times in 3 Posts Thanks: 5
Thanked 5 Times in 3 Posts
Rep Power: 2
|
Re: how to display tooltip for each item in multiselect box
thanks for ur prompt reply, i am using titile attribute in option tag to display tooltip, it is working fine with FireFox. but it has to work in IE also... mean while i wil try some other options... if u find any other solution,please let me know...
Regards , Ananth |
|
|
|
|
|
#9 (permalink) |
|
Super Moderator
Join Date: Feb 2006
Location: Hyderabad
Posts: 2,355
Thanks: 117 Thanked 241 Times in 198 Posts Thanks: 117
Thanked 241 Times in 198 Posts
Blog Entries: 4
Rep Power: 51
|
Re: how to display tooltip for each item in multiselect box
Ananth,
I am not sure about your requirements and pay lay out... but if you want a solution common to all platforms, I will suggest you to go for custom components (javascript based). You can create a select option look-alike by writing wrappers around "autofill" scripts which you can download from any site. Otherwise, there is not direct solution for this if you want to use only select option elements. Thanks, Krishna
__________________
Give 1 cup rice to a hungry Indian just by a mouse click. No money, no form filling, no hassle... Click here for the donation. |
|
|
|
| The Following User Says Thank You to sk_kireeti For This Useful Post: |
ananthkolli (26-11-07)
|
|
|
#10 (permalink) |
|
Member
Join Date: Apr 2007
Location: Right now in Chennai
Posts: 30
Thanks: 5 Thanked 5 Times in 3 Posts Thanks: 5
Thanked 5 Times in 3 Posts
Rep Power: 2
|
Re: how to display tooltip for each item in multiselect box
Hi,
we can provide the horizantal scroll bar using the div tag, for more details find the attachement. Thanks & Regards Ananth |
|
|
|
|
|
#11 (permalink) |
|
Moderator
Join Date: Apr 2006
Location: India
Posts: 636
Thanks: 57 Thanked 78 Times in 63 Posts Thanks: 57
Thanked 78 Times in 63 Posts
Rep Power: 17
|
Re: how to display tooltip for each item in multiselect box
Hello ananth and kireeti,
I think the discussion started somewhere and ended up some where , If im not wrong Ananth, here is the answer for your question, Simply add an attribute called as "title" Let me show you an example < textarea name="someName" title= "this is a title" > Some long texttttt < /title > If u are using some JSP scriptlets to display your text this is how ur code should look like < textarea name="someName" title= " < % =someLongText % >" >< % = SomeStrippedTextVariable% > < /textarea > On mouse over it automatically shows the long text Let me know your questions Thank You
__________________
M0h@n |
|
|
|
|
|
#12 (permalink) |
|
Moderator
Join Date: Apr 2006
Location: India
Posts: 636
Thanks: 57 Thanked 78 Times in 63 Posts Thanks: 57
Thanked 78 Times in 63 Posts
Rep Power: 17
|
Re: how to display tooltip for each item in multiselect box
On mouse over it automatically shows the long text
__________________
M0h@n |
|
|
|
|
|
#13 (permalink) |
|
Moderator
Join Date: Apr 2006
Location: India
Posts: 636
Thanks: 57 Thanked 78 Times in 63 Posts Thanks: 57
Thanked 78 Times in 63 Posts
Rep Power: 17
|
Re: how to display tooltip for each item in multiselect box
Please correct me if im wrong
__________________
M0h@n |
|
|