Microsoft Communities

Welcome to WindowsClient.net | Sign in | Join

Here are some frequently asked questions about Windows Forms and their answers.

Windows Forms FAQs

How do I get the Tooltips to be shown on a NumericUpDown control?

This is because of a bug in the .NET Framework. When tooltips are set on a control that hosts other controls within it (like the NumericUpDown), tooltips are not shown on those child controls. To workaround this issue, do the following in code:

[C#]

foreach ( Control c in numericUpDown1.Controls )
  tooltip.SetToolTip( c, "mytooltip" );

[Visual Basic]

Dim c As Control
For Each c In numericUpDown1.Controls
  tooltip.SetToolTip(c, "mytooltip")
Next

Contributed from George Shepherd's Windows Forms FAQ



Page view counter