Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Language Hyperlink - A Simple Newbie Question

Status
Not open for further replies.

humour

Programmer
Nov 24, 2003
87
I want to use the hyperlink class to set a session variable that will control the language displayed on the website for the rest of the session.

I am sure this can be done... But I havent found an example on the net.

I want the equivelent of this code but for a hyperlink.

Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click
Session("language")="french"
End Sub
 
Rather than use a HyperLink control use a LinkButton. It will look exactly the same but you can add your code to it's click event. e.g.
Code:
    Private Sub LinkButton1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles LinkButton2.Click
        Session("language") = "french"
    End Sub

----------------------------------------------------------------------

Need help finding an answer?

Try the search facilty ( or read FAQ222-2244 on how to get better results.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top