ISessionIDManager.InitializeRequest(HttpContext, Boolean, Boolean) Method


Performs per-request initialization of the SessionIDManager object.

 bool InitializeRequest(System::Web::HttpContext ^ context, bool suppressAutoDetectRedirect, [Runtime::InteropServices::Out] bool % supportSessionIDReissue);
public bool InitializeRequest (System.Web.HttpContext context, bool suppressAutoDetectRedirect, out bool supportSessionIDReissue);
abstract member InitializeRequest : System.Web.HttpContext * bool * bool -> bool
Public Function InitializeRequest (context As HttpContext, suppressAutoDetectRedirect As Boolean, ByRef supportSessionIDReissue As Boolean) As Boolean



The HttpContext object that contains information about the current request.


true if the session-ID manager should redirect to determine cookie support; otherwise, false to suppress automatic redirection to determine cookie support.


When this method returns, contains a Boolean that indicates whether the ISessionIDManager object supports issuing new session IDs when the original ID is out of date. This parameter is passed uninitialized.

Session ID reuse is appropriate when the session-state ID is encoded on a URL and the potential exists for the URL to be shared or emailed.

If a custom session-state implementation partitions cookies by virtual path, session state should also be supported.


true to indicate that the initialization performed a redirect; otherwise, false.


The InitializeRequest method is called for each request handled by the ISessionIDManager object. Use the InitializeRequest method to initialize per-request data for the SessionIDManager object.

When the suppressAutoDetectRedirect parameter is true, the ISessionIDManager object should not use redirection to determine whether the browser supports cookies.

The supportSessionIDReissue parameter should be returned false if cookies are used for session identification; otherwise, return true if your ISessionIDManager implementation supports re-issuing session IDs.

Applies to