Incorporating Help into Your Windows Applications

How much effort do you put into ensuring that your users get all the help they need? You probably strive to design a user-friendly user interface, but do you provide any avenue for your users to get help when they are stuck?

by Wei-Meng Lee

Jul 5, 2007

Page 1 of 3

elp is one of the most overlooked aspects of Windows development. Ask yourself this: for the last application that you finished and rolled out, how much effort did you put in to ensure that the users get all the help they need? No doubt you tried to design a user-friendly user interface, but did you provide any avenue for your users to get help when they are stuck?

This article discusses some ways to incorporate help into your application and make it much more user-friendly

Tooltips
The first (and easiest) way to create a help for your Windows application is to use Tooltips. A tooltip is a little graphical balloon that pops up when you position your cursor over an item, such as a Button or a CheckBox control.

Figure 1. Displaying a Tooltip: This is what it looks like when the mouse cursor hovers over the Button control.

In Windows Forms, you implement the Tooltip by using the Tooltip control (located in the Toolbox). You can also call it programmatically using the ToolTip class. For example, the following code snippet creates a ToolTip object, sets the message to display, and then binds itself to a Button control:

Dim tooltip1 As New ToolTip
With ToolTip1
.ToolTipTitle = "About Button1"
.SetToolTip(Button1, "Button 1 help string...")
End With

Figure 1 shows how it will look when the mouse cursor hovers over the Button control.

By default, the Tooltip is displayed as a rectangle. However, you can set the IsBalloon property to True to change it into a balloon (see also Figure 2):

Figure 2. Balloon Tooltip: Setting the IsBalloon property to True changes it into a balloon.

The ToolTip control also supports additional properties that allow you to control the duration for which it is displayed. For example, you can use the InitialDelay, ReshowDelay, and AutoPopDelay properties to control when the balloon is displayed and for how long:

With ToolTip1
.ToolTipTitle = "About Button1"
.SetToolTip(Button1, "Button 1 help string...")
'---time to wait before tip is shown for the first time---
.InitialDelay = 500
'---time to wait for subsequent display---
.ReshowDelay = 1000
'---time to show the tip---
.AutoPopDelay = 2000
End With

To ensure that all Tooltip balloons have consistent behaviors, you can set the AutomaticDelay property, which will automatically set the other properties. Simply use the formula shown below: