Losing Session State on postback event

N

none

Hi,

I've got a problem with losing session state in ASP.NET version 2.

It does it intermittently - sometimes it tanks - and sometimes it works OK.

I've got the ASP.NET state service started - the separate process for state management:
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
StateServer mode stores session state in a process, referred to as the ASP.NET
state service, that is separate from the ASP.NET worker process or IIS application
pool. Using this mode ensures that session state is preserved if the Web application
is restarted and also makes session state available to multiple Web servers in a
Web farm.

To use StateServer mode, you must first be sure the ASP.NET state service is running
on the server used for the session store. The ASP.NET state service is installed as
a service when ASP.NET and the .NET Framework are installed. The ASP.Net state
service is installed at the following location:
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-



... and I've made the proper entries in Web.config:
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
<sessionState mode="StateServer"
stateConnectionString="tcpip=localhost:42424"
cookieless="false"
timeout="20"/>

</system.web>
</configuration>

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-



I've set ASP.NET State Service startup type to "Automatic" in system services
- and I see that status is listed there as "started"
- and I see the active process listed in WinTasks as well.


Does anyone have any idea as to what is causing this?

Is there any way to get more information on this?

THANKS IN ADVANCE!



This is the error page:
##################################################################################
##################################################################################

Server Error in '/Webfolder01' Application.
--------------------------------------------------------------------------------

Object reference not set to an instance of an object.
Description: An unhandled exception occurred during the execution of the current
web request. Please review the stack trace for more information about the error
and where it originated in the code.

Exception Details: System.NullReferenceException: Object reference not set to
an instance of an object.

Source Error:


Line 1382: (ArrayList DC_ndx_array)
Line 1383: {
Line 1384: int lcl_DC_ndx, maxc = DC_ndx_array.Count;
Line 1385: string sav_ctrl_ID, next_ctrl_ID;
Line 1386: ArrayList next_DC_ndx_array;


Source File: i:\Virtual Webfolders\CtrlInit\CtrlRay.cs Line: 1384

Stack Trace:


[NullReferenceException: Object reference not set to an instance of an object.]
Ctrl_Array.dynamic_control_array_creation.generate_dynamic_control_structure
(ArrayList DC_ndx_array) in i:\Virtual Webfolders\CtrlInit\CtrlRay.cs:1384
dynamic_control_creation.load_dynamic_ctrl_struct02(Object sender, EventArgs e)
in i:\Virtual Webfolders\CtrlInit\dynctrl.cs:175
ASP.ctrlinit_ctrlinit12b_aspx.Page_Init(Object sender, EventArgs e)
in i:\Virtual Webfolders\CtrlInit\CtrlInit12b.aspx:37
System.Web.Util.CalliHelper.EventArgFunctionCaller
(IntPtr fp, Object o, Object t, EventArgs e) +15
System.Web.Util.CalliEventHandlerDelegateProxy.Callback
(Object sender, EventArgs e) +34
System.Web.UI.Control.OnInit(EventArgs e) +2069692
System.Web.UI.Page.OnInit(EventArgs e) +9
System.Web.UI.Control.InitRecursive(Control namingContainer) +321
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint,
Boolean includeStagesAfterAsyncPoint) +692


--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.42; ASP.NET
Version:2.0.50727.42
##################################################################################
##################################################################################



NOTE: DC_ndx_array gets assigned an ArrayList from a key/value pair in session state.


..
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,185
Members
46,736
Latest member
AdolphBig6

Latest Threads

Top