So I’m trying to do a Server.Transfer from a generic handler to an regular ASPX page.
It transfers okay, but it’s finding the HttpContext.Current.Session is null.
Anyone know why?
Thanks for the help!
-Ev
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You got to mark handler with IRequiresSessionState marker interface in order to have Session initialized. If you only need to read from session use IReadOnlySessionState marker interface, so Session State Provider can skip saving session at the end of request. In case of out of proc Session State Provider that can give some gains in performance.
Here is the example :