By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
440,016 Members | 2,255 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 440,016 IT Pros & Developers. It's quick & easy.

How can I capture the Script timeout Error?

P: n/a
Hi,

I need to capture the Script timeout error if that is possible. I know I can
increase the timeout value in the server settings or in the scripts itself
but I really want to make sure that no timeout situation will results as the
standard script timeout error page.

Can we do this ??

Help please.
Matt
Jul 19 '05 #1
Share this Question
Share on Google+
8 Replies


P: n/a
Turn off buffering and response.write during your loop. There isn't going
to be any scripting error if your page times out, so you have to find what
is causing things to take so long. It's often an endless loop.

Ray at work

"Mathieu Blais" <mb****@cmtek.com> wrote in message
news:OG**************@tk2msftngp13.phx.gbl...
Hi,

I need to capture the Script timeout error if that is possible. I know I can increase the timeout value in the server settings or in the scripts itself
but I really want to make sure that no timeout situation will results as the standard script timeout error page.

Can we do this ??

Help please.
Matt

Jul 19 '05 #2

P: n/a
Thanks Ray,

But how can I know that I have hit the time out ? Because I understand your
answer and it make sens but I don't just want not to receive any error
message, I want to know when it's happening in order to display a friendly
error message instead of the IIS error..

Matt
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Turn off buffering and response.write during your loop. There isn't going
to be any scripting error if your page times out, so you have to find what
is causing things to take so long. It's often an endless loop.

Ray at work

"Mathieu Blais" <mb****@cmtek.com> wrote in message
news:OG**************@tk2msftngp13.phx.gbl...
Hi,

I need to capture the Script timeout error if that is possible. I know I

can
increase the timeout value in the server settings or in the scripts itself but I really want to make sure that no timeout situation will results as

the
standard script timeout error page.

Can we do this ??

Help please.
Matt


Jul 19 '05 #3

P: n/a
Set the timeout to something ridiculously high, then write better code and
fix the timeout problem. I don't believe you can trap a script timeout
error.


"Matt" <mb****@cmtek.com> wrote in message
news:#6**************@tk2msftngp13.phx.gbl...
Thanks Ray,

But how can I know that I have hit the time out ? Because I understand your answer and it make sens but I don't just want not to receive any error
message, I want to know when it's happening in order to display a friendly
error message instead of the IIS error..

Jul 19 '05 #4

P: n/a
Ah, I see. Create a custom error page (500).

<%
Dim oError
Set oError = Server.GetLastError
Response.Write "Sorry, there was an error. The error was " &
oErr.Description
Set oError = Nothing

%>
Ray at work

"Matt" <mb****@cmtek.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl...
Thanks Ray,

But how can I know that I have hit the time out ? Because I understand your answer and it make sens but I don't just want not to receive any error
message, I want to know when it's happening in order to display a friendly
error message instead of the IIS error..

Matt
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl...
Turn off buffering and response.write during your loop. There isn't going
to be any scripting error if your page times out, so you have to find what is causing things to take so long. It's often an endless loop.

Ray at work

"Mathieu Blais" <mb****@cmtek.com> wrote in message
news:OG**************@tk2msftngp13.phx.gbl...
Hi,

I need to capture the Script timeout error if that is possible. I know
I can
increase the timeout value in the server settings or in the scripts itself but I really want to make sure that no timeout situation will results

as the
standard script timeout error page.

Can we do this ??

Help please.
Matt



Jul 19 '05 #5

P: n/a
Yes, and take Aaron's suggestion at determining what is causing the timeout.
What is causing it?

Ray at work
Jul 19 '05 #6

P: n/a
Oh I have no control on that, the script timeout because of the response
time of a distant database server and I have no control on it's performance
so I was wondering if I had any possibilities to trap this error.

Thanks anyway everybody. I'll do it like I was going to in the first place.
Increasing the timeout.
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:eD*************@TK2MSFTNGP09.phx.gbl...
Yes, and take Aaron's suggestion at determining what is causing the timeout. What is causing it?

Ray at work

Jul 19 '05 #7

P: n/a
Did you not like the custom error page idea?

Ray at work

"Matt" <mb****@cmtek.com> wrote in message
news:ec**************@TK2MSFTNGP12.phx.gbl...
Oh I have no control on that, the script timeout because of the response
time of a distant database server and I have no control on it's performance so I was wondering if I had any possibilities to trap this error.

Thanks anyway everybody. I'll do it like I was going to in the first place. Increasing the timeout.
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:eD*************@TK2MSFTNGP09.phx.gbl...
Yes, and take Aaron's suggestion at determining what is causing the

timeout.
What is causing it?

Ray at work


Jul 19 '05 #8

P: n/a
Yes that's a great idea but unfortunately Im working with IIS 4.0 and
correct me if I'm worng but ASP 2.0 does not support this method? But even
if I can't use it I would have a couple of question for my personnal
benefit. I have never used that kind of Custom Error page. How does that
work ? Where do you save it ? Does it need to have a specefic name or
something ?

Thank you very much for your help.

Matt

"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:O$*************@TK2MSFTNGP10.phx.gbl...
Did you not like the custom error page idea?

Ray at work

"Matt" <mb****@cmtek.com> wrote in message
news:ec**************@TK2MSFTNGP12.phx.gbl...
Oh I have no control on that, the script timeout because of the response
time of a distant database server and I have no control on it's

performance
so I was wondering if I had any possibilities to trap this error.

Thanks anyway everybody. I'll do it like I was going to in the first

place.
Increasing the timeout.
"Ray at <%=sLocation%>" <myfirstname at lane34 dot com> wrote in message
news:eD*************@TK2MSFTNGP09.phx.gbl...
Yes, and take Aaron's suggestion at determining what is causing the

timeout.
What is causing it?

Ray at work



Jul 19 '05 #9

This discussion thread is closed

Replies have been disabled for this discussion.