PC Review


Reply
Thread Tools Rate Thread

Hover over items in ListBox

 
 
Phil Kelly
Guest
Posts: n/a
 
      25th Jul 2004
Hi

I have a list box that I would like users to be able to hover over each item
in the collection to receive an explanation (like a context-sensitive help I
suppose) of the item.

How can this be achieved? I can not find how to do it anywhere!

Phil


 
Reply With Quote
 
 
 
 
One Handed Man \( OHM - Terry Burns \)
Guest
Posts: n/a
 
      25th Jul 2004
The mouse hover event will fire once when you hover over the control, from
this event you can use the current mouse position to get the item and then
from this you can choose how to display text associate with it. This
following code will write the index to the output window, you just need to
decide how to display the data.

Private Sub ListBox1_MouseHover(ByVal sender As Object, ByVal e As
System.EventArgs) Handles ListBox1.MouseHover

Dim cc, sc As Point
cc = New Point
sc = New Point


sc = ListBox1.MousePosition()
cc = ListBox1.PointToClient(sc)

Debug.WriteLine(ListBox1.IndexFromPoint(cc))

End Sub

--

OHM ( Terry Burns )
. . . One-Handed-Man . . .

Time flies when you don't know what you're doing

"Phil Kelly" <(E-Mail Removed)> wrote in message
news:ce006q$pa5$(E-Mail Removed)...
> Hi
>
> I have a list box that I would like users to be able to hover over each

item
> in the collection to receive an explanation (like a context-sensitive help

I
> suppose) of the item.
>
> How can this be achieved? I can not find how to do it anywhere!
>
> Phil
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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
PowerPoint keeps crashing, over and over and over and over MB Microsoft Powerpoint 1 12th Jan 2010 08:00 PM
BCM shutting down over and over and over and over TheMurf Microsoft Outlook BCM 1 9th Mar 2007 03:32 PM
Getting same message over and over and over and over each day =?Utf-8?B?Z29pbmJhdHR5?= Microsoft Outlook 1 18th Nov 2005 10:52 PM
XP Login Over & Over & Over & Over Desert Rat Windows XP Help 1 30th Oct 2004 02:37 AM
Outlook 2002 crashes over and over and over and over and over and over typoo Microsoft Outlook Discussion 5 7th Mar 2004 08:12 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 01:20 PM.