-2

I am using session in 2 http handler and also added IRequiresSessionState , IReadOnlySessionState

Imports System.Web.SessionState
Public Class Handler : Implements IHttpHandler , IRequiresSessionState , IReadOnlySessionState 

In http handler 1 create session

context.Session("id") = "1"

and in http handler 2 access to session

Dim i As String = CStr(context.Session("id"))

The problem here is that http handler 2 session("id") = nothing

why???

AShelly
  • 34,686
  • 15
  • 91
  • 152
Hossein Rahmati
  • 205
  • 1
  • 2
  • 11

1 Answers1

1

remove IReadOnlySessionState

Royi Namir
  • 144,742
  • 138
  • 468
  • 792