System.Windows.Forms 1.0.5000.0 2.0.0.0 System.ComponentModel.Component System.ComponentModel.IExtenderProvider System.ComponentModel.ToolboxItemFilter("System.Windows.Forms", System.ComponentModel.ToolboxItemFilterType.Allow) System.ComponentModel.ProvideProperty("ToolTip", typeof(System.Windows.Forms.Control)) System.ComponentModel.DefaultEvent("Popup") With the class, you can provide hints to a user when the user places the pointer on a control. The class is typically used to alert users to the intended use of a control. For example, you can specify ToolTip text for a control that accepts a name, specifying the format of the name to be typed into the control. In addition to providing hints, you can also use the class to provide run time status information. For example, you can use the class to display connection speed and line quality data when the user moves the pointer onto a control that displays Internet connection status. The class can be used in any container. To explicitly specify a container, use the constructor. A single component typically is used to create ToolTips for multiple controls on a single form. After you create a , use a separate call to the method to associate ToolTip display text to an individual control. Then when the user moves the pointer on a control, the ToolTip with its text is displayed. You can call more than once for the same control to change the text that is associated with the control. To get the text that is associated with a control, use the method. To remove all ToolTip text associations with an instance of the class, use the method. ToolTip text is not displayed for controls that are disabled. Unless the property is set to true, ToolTips are not displayed when their container is inactive. The class provides the following properties and methods to modify the default behavior and appearance of a ToolTip. Category Associated members Manual display , , , , , ToolTip timing , , , , Content , , , , , Appearance , , , , , If you want to disable all ToolTip text so that it cannot be displayed in your application, you can use the property. Usually the ToolTip is drawn by the operating system, but to customize the appearance of the , you can set the property to true and handle the event. The class implements the interface, which has a single method, . ToolTips extend controls on the same form at design time, adding a ToolTip property. For more information about extender providers, see Extender Providers. Represents a small rectangular pop-up window that displays a brief description of a control's purpose when the user rests the pointer on the control. Constructor This constructor creates an instance of a ToolTip not associated with any container. Initializes a new instance of the without a specified container. 1.0.5000.0 2.0.0.0 Constructor The constructor enables you to associate a with any object. By associating the in this manner, you hand over control of the lifetime of the ToolTip to the . This can be useful if you use several components in your application, and want to dispose of all of them at the same time. For example, if you associate a , an , and a with a , calling on the will also force disposal of all of these components. Initializes a new instance of the class with a specified container. An that represents the container of the . 1.0.5000.0 2.0.0.0 Property System.ComponentModel.DefaultValue(true) System.Boolean To be added. With the property, you can enable or disable the display of ToolTip text for all controls that have text specified by this particular component. Although more than one component can be created and assigned to a form, setting the property to false only affects the current . You can enable users to set the value of this property in a form that provides application options. These options, in turn, provide the user with the ability to enable or disable the display of ToolTips in your application. Gets or sets a value indicating whether the ToolTip is currently active. 1.0.5000.0 2.0.0.0 Property System.ComponentModel.RefreshProperties(System.ComponentModel.RefreshProperties.All) System.ComponentModel.DefaultValue(500) System.Int32 To be added. The property enables you to set a single delay value, which is then used to set the values of the , , and properties. Each time the property is set, the following values are set by default. Property Default Value 10 times the property value. Equal to the property value. 1/5 of the property value. These properties can also be set independently once the property has been set. For more information, see the , , and properties. This property is typically used to provide a consistent delay pattern for your ToolTip windows. Gets or sets the automatic delay for the ToolTip. 1.0.5000.0 2.0.0.0 Property System.ComponentModel.RefreshProperties(System.ComponentModel.RefreshProperties.All) System.Int32 To be added. The property enables you to shorten or lengthen the time that the window is displayed when the pointer is on a control. For example, if you display extensive Help in a ToolTip window, you can increase the value of this property to ensure that the user has sufficient time to read the text. If you want to have a consistent delay pattern for your ToolTip windows, you can set the property. The property sets the , , and properties to initial values based on a single value. Every time the property is set, the property is set to 10 times the property value. Once the property is set, you can independently set the property, overriding the default value. The maximum time you can delay a popup is 5000 milliseconds. For longer durations, use the method to control the exact moment when the ToolTip is displayed. Gets or sets the period of time the ToolTip remains visible if the pointer is stationary on a control with specified ToolTip text. 1.0.5000.0 2.0.0.0 Property 2.0.0.0 System.ComponentModel.DefaultValue("Color [Info]") System.Drawing.Color To be added. Unless the ToolTip is owner-drawn, this property is ignored. The system default font is automatically used and can only be overridden by owner-drawing the ToolTip. For more information, see the property. Gets or sets the background color for the ToolTip. Method System.Boolean The method is the only member of the interface. This method returns true if the parameter is of type . Returns true if the ToolTip can offer an extender property to the specified target component. true if the class can offer one or more extender properties; otherwise, false. The target object to add an extender property to. 1.0.5000.0 2.0.0.0 Property 2.0.0.0 System.Windows.Forms.CreateParams To be added. The property should only be extended when you are wrapping a standard Windows control class or to set styles not provided by the namespace. For more information about creating control parameters, see the CreateWindow and CreateWindowEx functions and the CREATESTRUCT structure documentation in the Windows Platform SDK reference located in the MSDN Library. When overriding the property in a derived class, use the base class's property to extend the base implementation. Gets the creation parameters for the ToolTip window. Method System.Void To be added. To be added. Disposes of the component. 1.0.5000.0 2.0.0.0 Event 2.0.0.0 System.Windows.Forms.DrawToolTipEventHandler With the event, you can customize the appearance of the . The event is raised by the class when the is drawn and the property value is true and the property is false. The class contains all the information needed to paint the , including the ToolTip text, the , and the object on which the drawing should be done. To customize the look of the ToolTip, use the to determine the bounds of the ToolTip, and the object to perform your customized drawing. You can increase the bounds of the before it is shown by handling the event. For more information about handling events, see [<topic://cpconEventsOverview>]. Occurs when the ToolTip is drawn and the property is set to true and the property is false. Method System.Void This method overrides . Application code should not call this method; an object's method is automatically invoked during garbage collection, unless finalization by the garbage collector has been disabled by a call to the method. For more information, see [<topic://cpconFinalizeMethodscDestructors>], [<topic://cpconCleaningUpUnmanagedResources>], and [<topic://cpconOverridingFinalizeMethod>]. Releases the unmanaged resources and performs other cleanup operations before the is reclaimed by the garbage collector. 1.0.5000.0 2.0.0.0 Property 2.0.0.0 System.ComponentModel.DefaultValue("Color [InfoText]") System.Drawing.Color To be added. Use the and properties to modify the color scheme used by ToolTips. The system default font is automatically used and can only be overridden by owner-drawing the ToolTip. For more information, see the property. Gets or sets the foreground color for the ToolTip. Method System.String With the method, you can retrieve the ToolTip text for any control. If the ToolTip text changes dynamically in an application, you can use this method to find out what text is displayed at any point, depending on the state of the application. To change the text that a control is displaying, use the method. Retrieves the ToolTip text associated with the specified control. A containing the ToolTip text for the specified control. The for which to retrieve the text. 1.0.5000.0 2.0.0.0 System.ComponentModel.DefaultValue("") System.ComponentModel.Localizable(true) System.ComponentModel.Editor("System.ComponentModel.Design.MultilineStringEditor, System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a", "System.Drawing.Design.UITypeEditor, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a") Method 2.0.0.0 System.Void The method hides the ToolTip for the specified if it is currently being displayed. It does not disable or otherwise prevent the same ToolTip from being displayed in the future. To instead disable all ToolTip windows associated with the current component, set the property to false. Applications running in partial trust must assert the permission to use this method, as can hide the tip independent of user action. Hides the specified ToolTip window. The of the associated window or control that the ToolTip is associated with. Property System.ComponentModel.RefreshProperties(System.ComponentModel.RefreshProperties.All) System.Int32 To be added. With the property, you can shorten or lengthen the time that the waits before displaying a ToolTip window. If the value of the property is set to a value that is too long in duration, the user of your application might not know that your application provides ToolTip Help. You can use this property to ensure that the user has ToolTips displayed quickly by shortening the time specified. The value for this property cannot exceed 32767. If you want to have a consistent delay pattern for your ToolTip windows, you can set the property. The property sets the , , and properties to initial values based on a single time value. Every time the property is set, the property is set to the same value as the property. Once the property is set, you can independently set the property, overriding the default value. Gets or sets the time that passes before the ToolTip appears. 1.0.5000.0 2.0.0.0 Property 2.0.0.0 System.ComponentModel.DefaultValue(false) System.Boolean To be added. By default, ToolTips are displayed using bare rectangular windows. By setting the property to true, the ToolTip will be displayed using a balloon window. Gets or sets a value indicating whether the ToolTip should use a balloon window. Property 2.0.0.0 System.ComponentModel.DefaultValue(false) System.Boolean To be added. Usually, a is drawn by the operating system, but to customize the appearance of the you can set the property to true and handle the event. The property takes precedence over the property. If both are set to true, the will be displayed using a balloon window rather than an owner drawn window. Gets or sets a value indicating whether the ToolTip is drawn by the operating system or by code that you provide. Event 2.0.0.0 System.Windows.Forms.PopupEventHandler The event is raised whenever a ToolTip is displayed, either through an explicit call to one of the methods or when the class implicitly displays a ToolTip. This event can be canceled. Calling properties in this event that cause the underlying window handle to be recreated, such as , will result in an exception being thrown. Occurs before a ToolTip is initially displayed. This is the default event for the class. Method System.Void You can use this method to remove all ToolTip text that is associated with the component for all associated controls. To disable the display of text instead, use the property. To change the text for a single associated control, use the method. Removes all ToolTip text currently associated with the ToolTip component. 1.0.5000.0 2.0.0.0 Property System.ComponentModel.RefreshProperties(System.ComponentModel.RefreshProperties.All) System.Int32 To be added. With the property, you can shorten or lengthen the time that the 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 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 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 property to be used; otherwise the property value is used. If you want to have a consistent delay pattern for ToolTip windows, you can set the property. The property sets the , , and properties to initial values based on a single time value. Every time the property is set, the property is set to 1/5 of the property value. Once the property is set, you can independently set the property, overriding the default value. Gets or sets the length of time that must transpire before subsequent ToolTip windows appear as the pointer moves from one control to another. 1.0.5000.0 2.0.0.0 Method System.Void In addition to specifying the ToolTip text to display for a control, you can also use this method to modify the ToolTip text for a control. Calling the method more than once for a given control does not specify multiple ToolTip text to display for a control, but instead changes the current ToolTip text for the control. To determine the ToolTip text that is associated with a control at run time, use the method. As a general rule the text used should be short; however, you can insert line breaks by using the \r\n escape character sequence. Ampersands (&) in the text are handled as described by the property. Associates ToolTip text with the specified control. The to associate the ToolTip text with. The ToolTip text to display when the pointer is on the control. 1.0.5000.0 2.0.0.0 Method 2.0.0.0 System.Void The version of the method displays the ToolTip for the specified control modally; that is, the ToolTip will be displayed until the method is called, or until the parent form is minimized, hidden, or closed. The ToolTip is positioned in the center of the associated control. Applications running in partial trust must assert the permission to use this method, as can control the display and location of a ToolTip independent of user action. Sets the ToolTip text associated with the specified control, and displays the ToolTip modally. A containing the new ToolTip text. The to display the ToolTip for. Method 2.0.0.0 System.Void The parameter can specify a position outside the bounds of the associated control, its parent form, or even the desktop. The version of the method displays the ToolTip for the specified control modally; that is, the ToolTip will be displayed until the method is called, or until the parent form is minimized, hidden, or dismissed. Applications running in partial trust must assert the permission to use this method, as can control the display and location of a ToolTip independent of user action. Sets the ToolTip text associated with the specified control, and then displays the ToolTip modally at the specified relative position. A containing the new ToolTip text. The to display the ToolTip for. A containing the offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip. Method 2.0.0.0 System.Void The ToolTip is positioned in the center of the associated control represented by the parameter. To display the ToolTip modally, call the overloaded version of this method instead. Applications running in partial trust must assert the permission to use this method, as can control the display and location of a ToolTip independent of user action. Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration. A containing the new ToolTip text. The to display the ToolTip for. An containing the duration, in milliseconds, to display the ToolTip. Method 2.0.0.0 System.Void The parameter can specify a position outside the bounds of the associated control, its parent form, or even the desktop. The ToolTip is positioned in the center of the associated control. To display the ToolTip modally, call the overloaded version of this method instead. Applications running in partial trust must assert the permission to use this method, as can control the display and location of a ToolTip independent of user action. Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration at the specified relative position. A containing the new ToolTip text. The to display the ToolTip for. A containing the offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip. An containing the duration, in milliseconds, to display the ToolTip. Method 2.0.0.0 System.Void This version of the overloaded method operates identically to the version, except that the offset is specified as separate x- and y-coordinates instead of a . Applications running in partial trust must assert the permission to use this method, as can control the display and location of a ToolTip independent of user action. Sets the ToolTip text associated with the specified control, and then displays the ToolTip modally at the specified relative position. A containing the new ToolTip text. The to display the ToolTip for. The horizontal offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip. The vertical offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip. Method 2.0.0.0 System.Void This version of the overloaded method operates identically to the version, except that the offset is specified as separate x and y coordinates instead of a . To display the ToolTip modally, call the overloaded version of this method instead. Applications running in partial trust must assert the permission to use this method, as can control the display and location of a ToolTip independent of user action. Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration at the specified relative position. A containing the new ToolTip text. The to display the ToolTip for. The horizontal offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip. The vertical offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip. An containing the duration, in milliseconds, to display the ToolTip. Property System.ComponentModel.DefaultValue(false) System.Boolean To be added. With the property, you can display a ToolTip window even when the container of the is not active. You can use this feature in a modeless window application to enable ToolTip windows to be displayed regardless of which modeless window is active. This feature is also useful when you want to create a control by using the , which contains a number of controls within it that display ToolTip windows. Because the is often not the active window on a form, setting this property to true enables the controls within the to display ToolTip windows at any time. Gets or sets a value indicating whether a ToolTip window is displayed, even when its parent control is not active. 1.0.5000.0 2.0.0.0 Method 2.0.0.0 System.Void The class has an internal timer that it uses to set the display duration for ToolTips. The duration associated with this timer is set through the property. The method will stop this internal timer, causing any displayed ToolTip to be shown modally until the method is called, or the parent form is minimized, hidden, or closed. Stops the timer that hides displayed ToolTips. Property 2.0.0.0 System.ComponentModel.DefaultValue(false) System.ComponentModel.Browsable(true) System.Boolean To be added. An application commonly uses the same string resource for multiple purposes, such as a menu item and a ToolTip. However, menus often enable accelerators, denoted by an ampersand character, in the menu item string. ToolTips do not support this capability, so by default, ampersands are just displayed as normal characters. Setting the property to true removes all ampersands from the ToolTip text. Gets or sets a value that determines how ampersand (&) characters are treated. Property 2.0.0.0 System.ComponentModel.DefaultValue(null) System.ComponentModel.TypeConverter(typeof(System.ComponentModel.StringConverter)) System.ComponentModel.Bindable(true) System.ComponentModel.Localizable(false) System.Object To be added. Typically, you use the property to store data that is closely associated with the . For example, if you are displaying a for a control that displays customer information, you might store the that contains the customer's information in the property so the data can be accessed quickly. Gets or sets the object that contains programmer-supplied data associated with the . Property 2.0.0.0 System.ComponentModel.DefaultValue(System.Windows.Forms.ToolTipIcon.None) System.Windows.Forms.ToolTipIcon To be added. If you want to use a graphic that is not defined by the enumeration, you must owner-draw the entire ToolTip. For more information, see the property. Gets or sets a value that defines the type of icon to be displayed alongside the ToolTip text. Property 2.0.0.0 System.ComponentModel.DefaultValue("") System.String To be added. The title is displayed within the window as a line of bold text above the standard text of a ToolTip control description. Typically, titles are only used either to differentiate different categories of controls on a form or as an introduction to a fairly long control description. The maximum length of a title is 99 characters. If this property contains a string longer then 99 characters, no title will be displayed. Gets or sets a title for the ToolTip window. Method System.String This overridden version of the method displays the class name, followed by the values of the and properties. Returns a string representation for this control. A containing a description of the . 1.0.5000.0 2.0.0.0 Property 2.0.0.0 System.ComponentModel.DefaultValue(true) System.ComponentModel.Browsable(true) System.Boolean To be added. Internet Explorer 5 and Microsoft Windows XP introduced dynamic user interface effects such as window fading and animation. If the user has not disabled these capabilities, the property can be used to enable this capability for ToolTips displayed on these platforms. Gets or sets a value determining whether an animation effect should be used when displaying the ToolTip. Property 2.0.0.0 System.ComponentModel.DefaultValue(true) System.ComponentModel.Browsable(true) System.Boolean To be added. Internet Explorer 5 and Microsoft Windows XP introduced dynamic user interface effects such as window fading and animation. If the user has not disabled these capabilities, the property can be used to enable this capability for ToolTips displayed on these platforms. Gets or sets a value determining whether a fade effect should be used when displaying the ToolTip.