SIGN UP MEMBER LOGIN:    
ARTICLE

ToolTip in Windows Application

Posted by Syed Shakeer Articles | Windows Forms C# January 20, 2011
Using the ToolTip class, you can provide hints to a user when the user places the pointer on a control. The ToolTip class is typically used to alert users to the intended use of a control.
Reader Level:

Using the ToolTip class, you can provide hints to a user when the user places the pointer on a control. The ToolTip class is typically used to alert users to the intended use of a control.

  1. ToolTip.IsBalloon Property:- To show Balloon using ToolTip,set the Property IsBalloon=true with the ToolTip object as follows:

    ToolTipobject.IsBalloon = true;
     
  2. ToolTip.ShowAlways Property:- Sets the ShowAlways property to true to enable ToolTip text to be displayed regardless of whether the form is active as follows:

    ToolTipobject.ShowAlways = true;
     
  3. ToolTip.ToolTipTitle Property:- Sets a title for the ToolTip window. The maximum length of a title is 99 characters. If this property contains a string longer then 99 characters, no title will be displayed.

    ToolTipobject.ToolTipTitle="User Title";
     
  4. ToolTip.SetToolTip Method:- SetToolTip () is used Set up the ToolTip text for the Button.

    ToolTipobject.SetToolTip(button1, "Hi User,Click me.");

    For Example:

    private void toolTip1_Popup(object sender, PopupEventArgs e)
    {
    ToolTip buttonToolTip = new ToolTip();
    buttonToolTip.ToolTipTitle =
    "Button Tooltip";
    buttonToolTip.IsBalloon =
    true;
    buttonToolTip.ShowAlways =
    true;
    buttonToolTip.SetToolTip(button1,
    "Hi User,Click me.");
    }

    Tooltip1.gif

    ToolTip.BackColor Property:

    BackColor Property is used Gets or sets the background color for the ToolTip.

    ToolTipobject.BackColor = System.Drawing.Color.Navy;

    ToolTip.ForeColor Property:

    ForeColor Property is used Gets or sets the foreground color for the ToolTip.

    ToolTipobject.ForeColor = System.Drawing.Color.Red;

     Tooltip2.gif

Login to add your contents and source code to this article
share this article :
post comment
 

Thanks Bro , m watching ur code first time ....its cool and m using ur tooltip codde...Thnks ..Keeeeeeeeeeep Rockingggggg ...TC :-)

Posted by surender bhyan Apr 01, 2011
6 Months Free & No Setup Fees ASP.NET Hosting!
Become a Sponsor
PREMIUM SPONSORS
  • Finally – a virtual platform that delivers next-generation Windows Server 2008 Hyper-V virtualization technology from a managed hosting partner you can truly depend on. Visit www.maximumasp.com/max for a FREE 30 day trial. Hurry offer ends soon. Climb aboard the MaxV platform and take advantage of High Availability, Intelligent Monitoring, Recurrent Backups, and Scalability – with no hassle or hidden fees. As a managed hosting partner focused solely on Microsoft technologies since 2000, MaximumASP is uniquely qualified to provide the superior support that our business is built on. Unparalleled expertise with Microsoft technologies lead to working directly with Microsoft as first to offer IIS 7 and SQL 2008 betas in a hosted environment; partnering in the Go Live Program for Hyper-V; and product co-launches built on WS 2008 with Hyper-V technology.
    Finally – a virtual platform that delivers next-generation Windows Server 2008 Hyper-V virtualization technology from a managed hosting partner you can truly depend on. Visit www.maximumasp.com/max for a FREE 30 day trial. Hurry offer ends soon. Climb aboard the MaxV platform and take advantage of High Availability, Intelligent Monitoring, Recurrent Backups, and Scalability – with no hassle or hidden fees. As a managed hosting partner focused solely on Microsoft technologies since 2000, MaximumASP is uniquely qualified to provide the superior support that our business is built on. Unparalleled expertise with Microsoft technologies lead to working directly with Microsoft as first to offer IIS 7 and SQL 2008 betas in a hosted environment; partnering in the Go Live Program for Hyper-V; and product co-launches built on WS 2008 with Hyper-V technology.
Nevron Gauge for SharePoint
Become a Sponsor