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 Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Setting a Session Variable on Click

Status
Not open for further replies.

jloffredo

Technical User
Joined
Feb 24, 2002
Messages
17
Location
US
How do I pass a value to a session variable when a link is clicked?
 
You could embed the value that you wish to set into the QueryString of your link.

On first page:
<a href="[highlight]?MyValue=Fred[/highlight]">Click here</a>

On second page:
Session("MySessionVar") = Request.QueryString("MyValue")
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top