LinkLabel.BorderStyle : LinkLabel « System.Windows.Forms « VB.Net by API






LinkLabel.BorderStyle

  

imports System
imports System.Drawing
imports System.Windows.Forms

public class LinkLabelsLinkArea : inherits Form
  dim lnkMsft as LinkLabel
  dim lnkLA as LinkLabel

  public sub New()
    Size = new Size(300,250)

    '  use Text property & LinkArea
    lnkMsft = new LinkLabel()
    lnkMsft.Parent = me
    lnkMsft.Text = "www.microsoft.com"
    lnkMsft.Location = new Point(0,0)
    lnkMsft.AutoSize = true
    lnkMsft.BorderStyle = BorderStyle.None
    lnkMsft.LinkArea = new LinkArea(4,9)
    AddHandler lnkMsft.LinkClicked, AddressOf lnkMsft_LinkClicked

  end sub

  public shared sub Main() 
    Application.Run(new LinkLabelsLinkArea())
  end sub

  private sub lnkMsft_LinkClicked(ByVal sender as object,  ByVal e as LinkLabelLinkClickedEventArgs)
      lnkMsft.Links(lnkMsft.Links.IndexOf(e.Link)).Visited = true
       System.Diagnostics.Process.Start(lnkMsft.Text)
  end sub

end class

   
    
  








Related examples in the same category

1.LinkLabel.ActiveLinkColor
2.LinkLabel.Link.LinkData
3.LinkLabel.LinkArea
4.LinkLabel.LinkClicked
5.LinkLabel.LinkVisited
6.LinkLabel.Links.Add
7.LinkLabel.Links.IndexOf
8.LinkLabel.VisitedLinkColor