Export (0) Print
Expand All

ToolTip.ReshowDelay Property

Gets or sets the length of time that must transpire before subsequent ToolTip windows appear as the pointer moves from one control to another.

Namespace:  System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)

public int ReshowDelay { get; set; }

Property Value

Type: System.Int32
The length of time, in milliseconds, that it takes subsequent ToolTip windows to appear.

With the ReshowDelay property, you can shorten or lengthen the time that the ToolTip waits before displaying a ToolTip window after a previous ToolTip window is displayed. The first time a ToolTip window is displayed, the value of the InitialDelay property is used to determine the delay to apply before initially showing the ToolTip window. When a ToolTip window is currently being displayed and the user moves the pointer to another control that displays a ToolTip window, the value of the ReshowDelay property is used before showing the ToolTip for the new control. The ToolTip window from the previous control must still be displayed in order for the delay specified in the ReshowDelay property to be used; otherwise the InitialDelay property value is used.

If you want to have a consistent delay pattern for ToolTip windows, you can set the AutomaticDelay property. The AutomaticDelay property sets the AutoPopDelay, ReshowDelay, and InitialDelay properties to initial values based on a single time value. Every time the AutomaticDelay property is set, the ReshowDelay property is set to 1/5 of the AutomaticDelay property value. Once the AutomaticDelay property is set, you can independently set the ReshowDelay property, overriding the default value.

The following code example creates an instance of the ToolTip class and associates the instance with the Form that the instance is created within. The code then initializes the delay properties AutoPopDelay, InitialDelay, and ReshowDelay. In addition the instance of the ToolTip class sets the ShowAlways property to true to enable ToolTip text to be displayed regardless of whether the form is active. Finally, the example associates ToolTip text with two controls on a form, a Button and a CheckBox. The code example requires that the method defined in the example is located within a Form that contains a Button control named button1 and a CheckBox control named checkBox1, and that the method is called from the constructor of the Form.

      // This example assumes that the Form_Load event handling method 
      // is connected to the Load event of the form. 
      private void Form1_Load(object sender, System.EventArgs e)
      {
         // Create the ToolTip and associate with the Form container.
         ToolTip toolTip1 = new ToolTip();

         // Set up the delays for the ToolTip.
         toolTip1.AutoPopDelay = 5000;
         toolTip1.InitialDelay = 1000;
         toolTip1.ReshowDelay = 500;
         // Force the ToolTip text to be displayed whether or not the form is active.
         toolTip1.ShowAlways = true;
			
         // Set up the ToolTip text for the Button and Checkbox.
         toolTip1.SetToolTip(this.button1, "My button1");
         toolTip1.SetToolTip(this.checkBox1, "My checkBox1");
      }

.NET Framework

Supported in: 4.5, 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft