Welcome to WebmasterWorld Guest from 18.206.168.65

Forum Moderators: ocean10000

Message Too Old, No Replies

Session Start event Firing Twice in a ASP.NET application

Session_start event firing twice.

     
10:21 am on Aug 20, 2009 (gmt 0)

New User

5+ Year Member

joined:Aug 20, 2009
posts: 2
votes: 0


I have an aspx which contains the 3 frames in which the source of each frame is again an aspx page. I am capturing some information on Session_start event in Global.asax file. Interestingly session_start event is firing twice. Tired of find this how?...

Any help would be greatly appreciated.

11:38 am on Aug 20, 2009 (gmt 0)

Senior Member

WebmasterWorld Senior Member 10+ Year Member

joined:Feb 1, 2005
posts:732
votes: 0


Hi Narasimha, Welcome to Webmasterworld [webmasterworld.com]!

AFAIK each frame maintains it's own session, but I could be wrong as I never work with frames. (and in your case it would mean firing 3x)

Here is an older thread on the subject with some ideas:
[webmasterworld.com...]

12:04 pm on Aug 20, 2009 (gmt 0)

New User

5+ Year Member

joined:Aug 20, 2009
posts:2
votes: 0


Hi Marcel,
Thanks for your quick response. I have already checked the above link what you mentioned.

I checked in my application that all the pages the autoeventwire attribute is set to false only.

The strange thing here is 1st time the session_start fires from main.aspx and second time session_start event fires from the login.aspx page after i submit the userid and pwd password. That to this is happening only in the application initiation.

So, i guess having 3 frames is not the problem. pls correct me if iam wrong.

Any thoughts on this?..

1:43 pm on Aug 20, 2009 (gmt 0)

Administrator

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month

joined:Jan 14, 2004
posts:864
votes: 3


Most Browsers limit the number of connections to single server to 2. So 3 frames loading at once only 2 can hit, then the 3rd would wait till one of the original two return before being requested. And since we are using frames the two frames are requesting a new page and since the session has not been established yet, it is triggering the code twice.