The old topic: Session variables desappear.

D

danyadler

Hi All,

The old topic: Session variables desappear.
I cannot understand it! And it's driving me crazy!!

So most of my aspx pages works just fine, but only 2 pages decide that
after they are sent to the client, they clear all the session
variables.
I even wrote a log file to see before page_load and after page_load,
the count of session.keys is 11, and even ajaxed a request from these
pages to write the same log, and I see that when the page is loaded
still 11 variables, but when entering the onload function of the page,
0 variables!

This is beyond my logic.
How can a client side SPECIFIC page, decide to clear the server side
memory?!?

Using Windows 2003 SP1, and IIS 6.0.

Am I missing something??

Your help would be greatly appriciated.
Danny
 
L

Laurent Bugnion [MVP]

Hi,

Hi All,

The old topic: Session variables desappear.
I cannot understand it! And it's driving me crazy!!

So most of my aspx pages works just fine, but only 2 pages decide that
after they are sent to the client, they clear all the session
variables.
I even wrote a log file to see before page_load and after page_load,
the count of session.keys is 11, and even ajaxed a request from these
pages to write the same log, and I see that when the page is loaded
still 11 variables, but when entering the onload function of the page,
0 variables!

This is beyond my logic.
How can a client side SPECIFIC page, decide to clear the server side
memory?!?

Using Windows 2003 SP1, and IIS 6.0.

Am I missing something??

Your help would be greatly appriciated.
Danny

Try attaching a debugger to the ASPNET process, and place a breakpoint
in the Session_End method in the Global.asax class (you may need to add
that class and that method to your project). This will help you find out
if something causes the session to terminate.

HTH,
Laurent
 
A

Alvin Bruney [MVP]

Why don't you have a look at the event log to see if the application pool is
being recycled?

--
Regards,
Alvin Bruney
------------------------------------------------------
Shameless author plug
Excel Services for .NET is coming...
OWC Black book on Amazon and
www.lulu.com/owc
Professional VSTO 2005 - Wrox/Wiley
 
D

Danny Adler

Why don't you have a look at the event log to see if the application pool is
being recycled?

--
Regards,
Alvin Bruney
------------------------------------------------------
Shameless author plug
Excel Services for .NET is coming...
OWC Black book on Amazon andwww.lulu.com/owc
Professional VSTO 2005 - Wrox/Wiley












- Show quoted text -


Oh my god!
This is unbelieveable!

First of all, thank you for the replies and pointers.

But, problem solved.

Resolution:
1. Enter IIS.
2. Delete the virtual directory.
3. Recreate the virtual directory.
4. Reconfigure as it was before.
5. Overwrite the new web.config with the old one.
And that's it.

It took me 40 hours to get to this resolution. UNBELIEVEABLE.
The kind of situations when you don't know if to cry or jump out the
window.
Thanks to Microsoft!

Danny
 

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

Top