We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

ListBox with Tooltip

Thread ID:

Created:

Updated:

Platform:

Replies:

27707 Apr 15,2005 03:57 PM Apr 18,2005 02:31 PM Windows Forms 1
loading
Tags: Tools
Gurbhej Dhillon
Asked On April 15, 2005 03:57 PM

Hi, Is there a way to implement a ListBox with a tooltip for each list item. Is this something that would be part of a future release. Thanks.

Administrator [Syncfusion]
Replied On April 18, 2005 02:31 PM

Hi Gurbhej, The following code snippet shows how to implement per-item Tooltips for a ListBox, using ToolTipAdv and a MouseHover event handler: private void listBox1_MouseHover(object sender, System.EventArgs e) { try { this.toolTipAdv1.Text = this.listBox1.Items[this.listBox1.IndexFromPoint(this.listBox1.PointToClient(Control.MousePosition))].ToString(); this.toolTipAdv1.ShowPopup(new Point(Control.MousePosition.X - 4, Control.MousePosition.Y - toolTipAdv1.Size.Height + 4)); } catch { //The Mouse was pointing to blank space } } Hope this helps. Regards, Gregory Austin Syncfusion Inc.

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;