Remarks and code here assume you are working in Windows Forms, although I believe the content here should be equally relevant to WPF.
The problem here is that in 'BindToolTipsToControls' when you do this:
ToolTip toolTip = new ToolTip();
You create a new ToolTip.
That means when you mouse-hover over the Contol you are displaying two ToolTips: this is not a flaw in .NET or WinForms: a Control can have more than one ToolTip (why ? : better ask MicroSoft ?).
The solution is simple:
do not create a new ToolTip, but re-use the one already being used:
private void button2_Click(object sender, EventArgs e)
{
BindToolTipsToControls(toolTip1, label1, "another tooltip");
}
private void BindToolTipsToControls(ToolTip theToolTip, Control control, string tooltipMessage)
{
theToolTip.SetToolTip(control, tooltipMessage);
}
Note that the above example assumes you have more than one ToolTip: is that really necessary, when one ToolTip can be used for any number of Controls on a Form surface, or on Controls "nested" deep inside other Containers on a Form surface ?
May I suggest you review the properties and Events exposed by the ToolTip Control, and the concept of a "Component" in WinForms ... or its equivalent in WPF, and note that while you can easily infer a ToolTip must maintain an internal collection of Text to display for one, or many, Controls, you have no access to that collection except the RemoveAll() method. And note that given a Control, you have no way to know ... say by accessing a property of that control ... if that Control has a ToolTip, or ToolTips.
For this reason, a Component like a ToolTip is often referred to as an Extender, or Provider.
Why does the ToolTip Control appear in the VS Studio Pro 2010 ToolBox sub-menus under "Common Controls," and not "Components" ? Better ask Microsoft :): even the tooltip on the ToolTip Control tells you it is a Component.