I have have an application that am playing with that is pretty much a dashboard that will be displayed on a big monitor in a lunch room wall type of situation. It uses a timer to refresh charts.
Every night when IIS recycles, it kicks me out with an invalid session. I understand why it is doing this because the application pool is shutdown and sessions are lost.
Is there any way for me to set something up so that my application could know that the session went invalid and after 10,20 seconds tried to connect again?
As additional info…
I was thinking I could save what form was showing into a cookie and then when the app came back up, the program.vb would look in the cookie to see what dashboard form to display.
If you add the script below to Default.html you can handle any exception on the client side. The InvalidSession exception has the message = “Invalid Session” and a flag invalidSession = true. The message text can be localized, so it’s better to check the flag.
Wisej.onException = function(ex)
As soon as wisej (client) detects an invalid session it will reload the page.
I don’t know if this is applicable but as a workaround you could tell it to never recycle or increase it to something like a week. The only reason why it really recycles I believe is to solve memory or handle leaks that a software developer might have created. There is actually no need unless you are seeing issues with it running for so long.