LinkLabel Control.


The LinkLabel control is similiar to the label control, with the exception of hyperlinks. The LinkLabel control can display single or multiple hyperlinks. When the user clicks a hyperlink, the process can be started in th event.  



Namespace: System.Windows.Forms
Assembly: Systems.Windows.Forms.dll

using System.Windows.Forms;
Calling: System.Windows.Forms.LinkLabel

Creating a new System.Windows.Forms.LinkLabel control.
LinkLabel linkLabel1 = new LinkLabel();

Adding the LinkLabel control to a Windows form.
this.Controls.Add(linkLabel1);

Assigning text to the LinkLabel control.
linkLabel1.Text = "DotNet Controls";

Using an image with the LinkLabel control.
linkLabel1.Image = Image.FromFile(@"c:\Icons\helloworld.gif");

To create a click event to handle the linklabel click.
linkLabel1.LinkClicked+=new LinkLabelLinkClickedEventHandler(linkLabel1_LinkClicked);

To respond to the linklabel click event.
private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e) { System.Diagnostics.Process.Start("www.speakcomputers.com"); }


 
C# Controls.
ButtonControl
ComboBox Control
CheckBox Control
ListBox Control
ListView Control
Label Control
LinkLabel Control
MenuStrip Control
Mdi Control
RadioButton Control
RichText Box
SystemSpeech API
SystemIO Images
TextBox Control
TreeView Control
WebBrowser Control
Programming Books
Related.
DevComponents
Infragistics
Visual Studio
ASP.NET
Top of page
Copy Right 2006 SpeakComputers.com, All Rights Reserved.

Home |  XBOX Console and Games | Windows Vista | Text to Speech | Learn HTML | Programming with C# | AntiVirus Software | Internet Security
Site Map | Contact SpeakComputers.com | Privacy Policy | Web Directory