ToolTip.Show Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Sets the text associated with a ToolTip, and then displays it.
Overloads
Show(String, IWin32Window, Int32, Int32) |
Sets the ToolTip text associated with the specified control, and then displays the ToolTip modally at the specified relative position. |
Show(String, IWin32Window, Point, Int32) |
Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration at the specified relative position. |
Show(String, IWin32Window, Int32, Int32, Int32) |
Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration at the specified relative position. |
Show(String, IWin32Window, Point) |
Sets the ToolTip text associated with the specified control, and then displays the ToolTip modally at the specified relative position. |
Show(String, IWin32Window) |
Sets the ToolTip text associated with the specified control, and displays the ToolTip modally. |
Show(String, IWin32Window, Int32) |
Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration. |
Show(String, IWin32Window, Int32, Int32)
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
Sets the ToolTip text associated with the specified control, and then displays the ToolTip modally at the specified relative position.
public:
void Show(System::String ^ text, System::Windows::Forms::IWin32Window ^ window, int x, int y);
public void Show (string text, System.Windows.Forms.IWin32Window window, int x, int y);
public void Show (string? text, System.Windows.Forms.IWin32Window window, int x, int y);
member this.Show : string * System.Windows.Forms.IWin32Window * int * int -> unit
Public Sub Show (text As String, window As IWin32Window, x As Integer, y As Integer)
Parameters
- window
- IWin32Window
The Control to display the ToolTip for.
- x
- Int32
The horizontal offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip.
- y
- Int32
The vertical offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip.
Remarks
This version of the overloaded Show method operates identically to the Show(String, IWin32Window, Point) version, except that the offset is specified as separate x- and y-coordinates instead of a Point.
Applications running in partial trust must assert the AllWindows permission to use this method, as Show can control the display and location of a ToolTip independent of user action.
See also
- Hide(IWin32Window)
- GetToolTip(Control)
- SetToolTip(Control, String)
- IsBalloon
- StripAmpersands
- ToolTipTitle
- ToolTipIcon
- OwnerDraw
- Popup
Applies to
Show(String, IWin32Window, Point, Int32)
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration at the specified relative position.
public:
void Show(System::String ^ text, System::Windows::Forms::IWin32Window ^ window, System::Drawing::Point point, int duration);
public void Show (string text, System.Windows.Forms.IWin32Window window, System.Drawing.Point point, int duration);
public void Show (string? text, System.Windows.Forms.IWin32Window window, System.Drawing.Point point, int duration);
member this.Show : string * System.Windows.Forms.IWin32Window * System.Drawing.Point * int -> unit
Public Sub Show (text As String, window As IWin32Window, point As Point, duration As Integer)
Parameters
- window
- IWin32Window
The Control to display the ToolTip for.
- point
- Point
A Point containing the offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip.
Exceptions
The window
parameter is null
.
duration
is less than or equal to 0.
Remarks
The pt
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 Show(String, IWin32Window, Point) overloaded version of this method instead.
Applications running in partial trust must assert the AllWindows permission to use this method, as Show can control the display and location of a ToolTip independent of user action.
See also
- Hide(IWin32Window)
- GetToolTip(Control)
- SetToolTip(Control, String)
- IsBalloon
- StripAmpersands
- ToolTipTitle
- ToolTipIcon
- OwnerDraw
- Popup
Applies to
Show(String, IWin32Window, Int32, Int32, Int32)
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration at the specified relative position.
public:
void Show(System::String ^ text, System::Windows::Forms::IWin32Window ^ window, int x, int y, int duration);
public void Show (string text, System.Windows.Forms.IWin32Window window, int x, int y, int duration);
public void Show (string? text, System.Windows.Forms.IWin32Window window, int x, int y, int duration);
member this.Show : string * System.Windows.Forms.IWin32Window * int * int * int -> unit
Public Sub Show (text As String, window As IWin32Window, x As Integer, y As Integer, duration As Integer)
Parameters
- window
- IWin32Window
The Control to display the ToolTip for.
- x
- Int32
The horizontal offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip.
- y
- Int32
The vertical offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip.
Exceptions
The window
parameter is null
.
duration
is less than or equal to 0.
Remarks
This version of the overloaded Show method operates identically to the Show(String, IWin32Window, Point, Int32) version, except that the offset is specified as separate x and y coordinates instead of a Point. To display the ToolTip modally, call the Show(String, IWin32Window, Int32, Int32) overloaded version of this method instead.
Applications running in partial trust must assert the AllWindows permission to use this method, as Show can control the display and location of a ToolTip independent of user action.
See also
- Hide(IWin32Window)
- GetToolTip(Control)
- SetToolTip(Control, String)
- IsBalloon
- StripAmpersands
- ToolTipTitle
- ToolTipIcon
- OwnerDraw
- Popup
Applies to
Show(String, IWin32Window, Point)
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
Sets the ToolTip text associated with the specified control, and then displays the ToolTip modally at the specified relative position.
public:
void Show(System::String ^ text, System::Windows::Forms::IWin32Window ^ window, System::Drawing::Point point);
public void Show (string text, System.Windows.Forms.IWin32Window window, System.Drawing.Point point);
public void Show (string? text, System.Windows.Forms.IWin32Window window, System.Drawing.Point point);
member this.Show : string * System.Windows.Forms.IWin32Window * System.Drawing.Point -> unit
Public Sub Show (text As String, window As IWin32Window, point As Point)
Parameters
- window
- IWin32Window
The Control to display the ToolTip for.
- point
- Point
A Point containing the offset, in pixels, relative to the upper-left corner of the associated control window, to display the ToolTip.
Exceptions
The window
parameter is null
.
Remarks
The pt
parameter can specify a position outside the bounds of the associated control, its parent form, or even the desktop. The version of the Show method displays the ToolTip for the specified control modally; that is, the ToolTip will be displayed until the Hide method is called, or until the parent form is minimized, hidden, or dismissed.
Applications running in partial trust must assert the AllWindows permission to use this method, as Show can control the display and location of a ToolTip independent of user action.
See also
- Hide(IWin32Window)
- GetToolTip(Control)
- SetToolTip(Control, String)
- IsBalloon
- StripAmpersands
- ToolTipTitle
- ToolTipIcon
- OwnerDraw
- Popup
Applies to
Show(String, IWin32Window)
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
Sets the ToolTip text associated with the specified control, and displays the ToolTip modally.
public:
void Show(System::String ^ text, System::Windows::Forms::IWin32Window ^ window);
public void Show (string text, System.Windows.Forms.IWin32Window window);
public void Show (string? text, System.Windows.Forms.IWin32Window window);
member this.Show : string * System.Windows.Forms.IWin32Window -> unit
Public Sub Show (text As String, window As IWin32Window)
Parameters
- window
- IWin32Window
The Control to display the ToolTip for.
Exceptions
The window
parameter is null
.
Remarks
The version of the Show method displays the ToolTip for the specified control modally; that is, the ToolTip will be displayed until the Hide 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 AllWindows permission to use this method, as Show can control the display and location of a ToolTip independent of user action.
See also
- Hide(IWin32Window)
- GetToolTip(Control)
- SetToolTip(Control, String)
- IsBalloon
- StripAmpersands
- ToolTipTitle
- ToolTipIcon
- OwnerDraw
- Popup
Applies to
Show(String, IWin32Window, Int32)
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
- Source:
- ToolTip.cs
Sets the ToolTip text associated with the specified control, and then displays the ToolTip for the specified duration.
public:
void Show(System::String ^ text, System::Windows::Forms::IWin32Window ^ window, int duration);
public void Show (string text, System.Windows.Forms.IWin32Window window, int duration);
public void Show (string? text, System.Windows.Forms.IWin32Window window, int duration);
member this.Show : string * System.Windows.Forms.IWin32Window * int -> unit
Public Sub Show (text As String, window As IWin32Window, duration As Integer)
Parameters
- window
- IWin32Window
The Control to display the ToolTip for.
Exceptions
The window
parameter is null
.
duration
is less than or equal to 0.
Remarks
The ToolTip is positioned in the center of the associated control represented by the win
parameter. To display the ToolTip modally, call the Show(String, IWin32Window) overloaded version of this method instead.
Applications running in partial trust must assert the AllWindows permission to use this method, as Show can control the display and location of a ToolTip independent of user action.
See also
- Hide(IWin32Window)
- GetToolTip(Control)
- SetToolTip(Control, String)
- IsBalloon
- StripAmpersands
- ToolTipTitle
- ToolTipIcon
- OwnerDraw
- Popup
Applies to
.NET