Open an Internet Explorer page

  • Thread starter Thread starter ALI-R
  • Start date Start date
A

ALI-R

I want when user clicks on LinkedLable ,an IE page to an specific address
opens ,how can I do that?

thanks
 
Here's an example for a single link in a link label:

Private Sub Form1_Load(ByVal sender As Object, ByVal e As System.EventArgs)
_
Handles MyBase.Load
LinkLabel1.Links.Add(0, LinkLabel1.Text.Length, "www.google.com")
End Sub

Private Sub LinkLabel1_LinkClicked(ByVal sender As Object, _
ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) _
Handles LinkLabel1.LinkClicked
Dim URL As String = CStr(e.Link.LinkData())
System.Diagnostics.Process.Start(URL)
End Sub

If you want to have multiple links within a single link label, here's an
example from MSDN:
http://msdn.microsoft.com/library/d...ystemwindowsformslinklabelclasslinkstopic.asp


hope that helps..
Imran.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top