K
Kent Tegels
Okay, so I know I'm doing two evil things: using Frames
and storing stuff in Session. I'm a sinner and I'll
repent after this project, I promise.
But for now, I've got an interesting issue.
In a site's Gobal.asax, I've written the following in
Session_OnStart:
Session.Add("Started",now.toString)
I also have a WebForm named WebForm1.aspx (not feeling
overly creative today) where, in the PageLoad event, I've
added this:
Session.Add("PageLoad",now.toString)
Using Performance Monitor, I've watch the total of active
sessions when browsing WebForm1 .aspx. As expected, I get
use on (additional) session.
This site also has a frameset page in it (frameset1.htm)
and "contains" three webforms: Frame1.aspx, Frame2.aspx
and Frame3.aspx. Each of the /Frame\d.aspx/ files as
statement like the following in its PageLoad
event:
(note that /Frame\d.aspx/ is one of
frame1.aspx...frame3.aspx, I'm just used tro writing
Regular Expressions...)
Session.Add("Frame/\d/",now.toString)
Before browsing Frameset1.htm, I use IIS restart to
abadon and clean out all sessions. But when I browse
Frameset1.htm, I get not one, not two, but three active
sessions. Each of the Frame\d.aspx pages has label
controls that show the SessionID, the global "Started"
and local "Frame/\d/" value.
That begs three questions:
a. Why?
b. If I just want one session for all three frames, what
do I need to do?
c. Is this new behavior 1.1 or does it has it never
worked like I thought it would? (e.g, this is behavior by
design)
FWIW, I've also tried decorating the code
with "SyncBlock"s in the Frame/\d/.aspx pages, but it
doesn't seem to make a difference.
I think I have a partial answer: each frame is getting
its own session ID. I don't want that, I want them all to
have the same one.
BTW, I get the same results with fx1.0, but not with
fx1.2 (Whidbey... heh, something that does work there...)
Thanks,
Kent Tegels
and storing stuff in Session. I'm a sinner and I'll
repent after this project, I promise.
But for now, I've got an interesting issue.
In a site's Gobal.asax, I've written the following in
Session_OnStart:
Session.Add("Started",now.toString)
I also have a WebForm named WebForm1.aspx (not feeling
overly creative today) where, in the PageLoad event, I've
added this:
Session.Add("PageLoad",now.toString)
Using Performance Monitor, I've watch the total of active
sessions when browsing WebForm1 .aspx. As expected, I get
use on (additional) session.
This site also has a frameset page in it (frameset1.htm)
and "contains" three webforms: Frame1.aspx, Frame2.aspx
and Frame3.aspx. Each of the /Frame\d.aspx/ files as
statement like the following in its PageLoad
event:
(note that /Frame\d.aspx/ is one of
frame1.aspx...frame3.aspx, I'm just used tro writing
Regular Expressions...)
Session.Add("Frame/\d/",now.toString)
Before browsing Frameset1.htm, I use IIS restart to
abadon and clean out all sessions. But when I browse
Frameset1.htm, I get not one, not two, but three active
sessions. Each of the Frame\d.aspx pages has label
controls that show the SessionID, the global "Started"
and local "Frame/\d/" value.
That begs three questions:
a. Why?
b. If I just want one session for all three frames, what
do I need to do?
c. Is this new behavior 1.1 or does it has it never
worked like I thought it would? (e.g, this is behavior by
design)
FWIW, I've also tried decorating the code
with "SyncBlock"s in the Frame/\d/.aspx pages, but it
doesn't seem to make a difference.
I think I have a partial answer: each frame is getting
its own session ID. I don't want that, I want them all to
have the same one.
BTW, I get the same results with fx1.0, but not with
fx1.2 (Whidbey... heh, something that does work there...)
Thanks,
Kent Tegels