Click to See Complete Forum and Search --> : ListBox: items too long


Robert Maier
May 30th, 1999, 04:42 PM
In my application I use various listbox controls. In some case items are too long to be shown entirely in the listbox. From other applications I am used to listboxes, that show an item as a tooltip, when the mouse pointer is positioned over it. However, i have no idea how to find out, over which item the mouse pointer is, as long as no click event or the like has occured. Could please someone help? Another idea would be a horizontal scroll bar, but as far as I know, there is non for the ListBox control.
Reagrds
Robert

Crazy D
May 30th, 1999, 06:09 PM
Hi
The lstbox can have a horizontal scrollbar, but you need to use the api for that.
You should find it at http://www.codeguru.com/vb/Controls/ListBox/index.shtml
Crazy D :-)

Ravi Kiran
May 31st, 1999, 12:18 AM
Hi,

On the VBnet site, i have seen an example,

http://www.mvps.org/vbnet/code/listapi/rightmouseclick.htm

where he shows how to get the right mouse click, and how to get the current mouse position over the list box. From that index, you can get the list item text and display either in a status bar or as tool-tip .

Ravi Kiran