basic HTML link

whosyodaddy

Regular
Joined
Jun 23, 2003
Messages
83
what is the code for a basic HTML link? for some you put
""
"<a href=></a>"

what is the basic HTML code in VBNET to create a link to a website.
 
... VB.NET doesn't use HTML...

:confused:

Perhaps you would like to use the LinkLabel control? Also, you can use Process.Start("http://www.blah.com")to open the default browser to that page...
 
as voltface says use Process.Start , you could use a link label and do the following :
Visual Basic:
    Private Sub LinkLabel1_LinkClicked(ByVal sender As System.Object, ByVal e As System.Windows.Forms.LinkLabelLinkClickedEventArgs) Handles LinkLabel1.LinkClicked
        Dim proc As Process = New Process()
        e.Link.Visited = True '///make the link look like a clicked link in internet explorer.
        proc.Start("IEXPLORE", LinkLabel1.Text) '///launch an instance of internet explorer and navigate to the link off the label.
    End Sub
 
Actually, the better way to do it is this:
Visual Basic:
Process.Start("http://blah")
Rather than explicitly starting IEXPLORE. If you "run" a document with Process.Start it will open in the default associated app. You also don't need to create a new instance of a Process, unless you plan to handle its events.


Oh, and it's VolteFace. :mad: :D :D
 
sorry VolteFace , my spelling goes off after 8pm these days:-\
i generaly use Process so that i can handle it's events after , ie : closing the process from a list and stuff so i just go about it that way, i didnt know that you could just put the link in without IEXPLORE , so i learnt something myself lol.
 
Back
Top