Solved

Redirect Session time out runtime error to a custom error page

Posted on 2007-04-01
3
301 Views
Last Modified: 2008-03-06
Hi,

Having a vb.net application which hondles error messages using Error.aspx page. When session times out the 'yellow' runtime error is displayed. Session time out is defined within the web.config. I am not sure how to trap the runtime error so when ever session is ecpired then I redirect users to the same Error.aspx page.

Thanks in advance
0
Comment
Question by:shmz
3 Comments
 
LVL 28

Accepted Solution

by:
iboutchkine earned 500 total points
ID: 18835334
after body tag


<script language="javascript">
window.setTimeout("alert('you will be logged off in 5sec');",5000);
window.setTimeout("reDirect()",10000);

function reDirect() {
window.location.href = "http://www.google.com";
}
</script>
============================
redirect to another page when page timed out
<html>
<head>
<title>My Redirect</title>
</head>
<body>
This page will redirect to <b>http://www.msdn.microsoft.com</b> in 5
seconds.
</body>
<script language="javascript">
window.setTimeout("reDirect()",5000);

function reDirect() {
window.location.href = "http://www.msdn.microsoft.com";
}
</script>
</html>
=========================================
redirect to another pade after session expired

if Session.item("KEY") = Nothing then
   Response.Redirect("LoginPage.aspx")
end if
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

It seems a simple enough task, yet I see repeated questions asking how to do it: how to pass data between two forms. In this article, I will show you the different mechanisms available for you to do just that. This article is directed towards the .N…
A long time ago (May 2011), I have written an article showing you how to create a DLL using Visual Studio 2005 to be hosted in SQL Server 2005. That was valid at that time and it is still valid if you are still using these versions. You can still re…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question