Thursday, March 29, 2012

Session Variable

Hello,
Does anyone know if it is possible to set a session variable when a user
click on a HyperLink?
Thank
MLHave the page post back, set the session variable and either
Server.Transfer or Response.Redirect
Do you have an example page that show the principle?
Is it possible to do it without involving forms?
Thank
ML
<garethdjames@.gmail.com> wrote in message
news:1116602123.826280.245700@.o13g2000cwo.googlegroups.com...
> Have the page post back, set the session variable and either
> Server.Transfer or Response.Redirect
>
can you give me more details of what you want to do
Now I'm home and cannot see VS.Net, therefore I write what I remember, and
hope I don't tell you wrong things.
You should use the LinkButton whick looks similar to the HyperLink, and in
the Click event you can set the session variable and then link with:
Page.Response.Redirect("target.aspx");
Vanni Tomezzoli
S. Donato Mil., Milano, Italy
vannto@.tin.it
http://xoomer.virgilio.it/vtomezzo
"Michel Lapointe" <a@.a.com> ha scritto nel messaggio
news:u$x7N0UXFHA.1152@.tk2msftngp13.phx.gbl...
> Hello,
> Does anyone know if it is possible to set a session variable when a
user
> click on a HyperLink?
> Thank
> ML
>

0 comments:

Post a Comment