the session object dictionary is loaded at OnBeginRequest, and saved at
OnEndRequest. In between you just talk to the dictionary. this can lead to
some strange behavior
create session like:
Session["myobj"] = myObject;
Session["myobj2"] = myObject;
until session save, Session["myobj"] and Session["myobj2"] refer to the
same object, so changing value in one, changes it in both. but on the next
page request, they refer to different objects (because they each get
serialized).
-- bruce (sqlwork.com)
"Kevin Jackson" <kj******@powerwayinc.com> wrote in message
news:uv**************@TK2MSFTNGP09.phx.gbl...
Does accessing a session variable multiple times during the processing of
a page incur a hop each time it is accessed in State Server and SQL Server
modes? Or does the roundtrip occur just once and then the variable used
from a session cache for the rest of the request?
Is the session written out at the end of the request or when a session is
written to?