Accessing Session variables defined in ASP page in the ASPX page

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a session variable defined in the ASP page. This ASP application then
also uses ASPX pages. I am unable to read the value of the session variable
in the ASPX page. The value shown is empty.

What could be the reason? Please help.

Thanks
 
If you google this question, you will see that it has been asked hundreds of
times.

The answer, is that ASP and ASP.NET run as 2 different processes, and thus
cannot share session.
 
Sachin,

ASP and ASP.NET run in two completely different processes, so they
cannot share session values.

You can work around this by "mapping" values placed in classic ASP
session into ASP.NET session. This would take some additional code and
likely a redirect from the ASP that sets the session value to an ASPX
that will place the same value in ASP.NET session, but it can and has
been done before.

If you need more details, let me know and I'll dig up and post some
source code for you.

Thanks,
Denny
 
Hi Denny,

Thanks for the details. I would really appreciate if you can post some code,
showing what you have explained.

Thanks,
Sachin
 
¤ Hi Denny,
¤
¤ Thanks for the details. I would really appreciate if you can post some code,
¤ showing what you have explained.
¤

Check out Juan's post in the thread.


Paul
~~~~
Microsoft MVP (Visual Basic)
 
Back
Top