Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Timeout Error Messages

Status
Not open for further replies.

d1004

Programmer
May 9, 2002
78
0
0
US
My page generate the following error, does this mean I have to set my timeout property?


error 'ASP 0113'
Script timed out
/../..Tech.asp
The maximum amount of time for a script to execute was exceeded. You can change this limit by specifying a new value for the property Server.ScriptTimeOut or by changing the value in the IIS administration tools.
 
It depends on what your doing. If you are doing somthing that could conceivably take longer then the default 90 seconds, then yes you should extend it like so:
Server.ScriptTimeout = x 'where x is a number measured in seconds :)

so:
Server.ScriptTimeout = 15
would shorten my tinme out to 15 seconds, something I often do when testing my code.

The other possibility for the reason you received the above message is that you have an endless loop somewhere in your code and the server basicaly chugged along for the required minute and a half and then killed the script. In this case you wouldn't want to extend the timeout, you want to find the problem with your loop :)

Well, unless your burning your machine in ;)

-Tarwn ________________________________________________________________________________
Want to get great answers to your Tek-Tips questions? Have a look at faq333-2924
 
I put the <% Server.ScriptTimout = 120 %> on all my pages.
But I still got the error msg. This page run perfectly find before, but just
recently it gave me that error msg. It is something I need to get the server admin
to fix the server properties or is my page that's generating the error.
I check over my pages to see if I have a loop problem, but I don't think
it's that.
 
for fun I would try setting the timeout to something rediculous like
<% Server.ScriptTimout = 12000 %>
and see if it jsut runs to no end. then at that point you do ahve a loop problem or such. if it doesn't and it loads compeltely after so long then you just need to set the timeout to a longer period of time _______________________________________________
[sub]{ str = &quot;sleep is good for you. sleep gives you the energy you need to function&quot;;
ptr = /sleep/gi;Nstr = str.replace(ptr,&quot;coffee&quot;);alert(Nstr); }[/sub]
_______________________________________________
for the best results to your questions: FAQ333-2924
has you're questio
 
Here's an easy way to track down the error. At the top of your script turn off the response buffer:
Code:
Response.Buffer = False

Then put response.writes all through the code. Set the timeout to something like 30 seconds so you waon't have to wait long. Now load the page. Note the last one that got written, go to that section, put bunches more in. Keep doing so until you find the section that it just isn't getting past, and voila you'll have your answer.

It will either be:
a) A loop problem
b) A database problem
c) a loop problem caused by a database problem
d) an fso problem
e) a loop caused by an fso problem

I think thats everything I can think of to cause endless loops. And yes I consider a While true Wend loop to fall under a :)

-Tarwn ________________________________________________________________________________
Sometimes it is how you ask the question: faq333-2924
Many ASP questions have already been answered, please check faq333-3048 and use the search tool before posting
 
Well, I tried setting timeout to 12000, and it
generates the report within 10 minutes. That
is way too long compare to before,
it only takes less than a minute. So
I don't know what is going on.. If it generates
the page, it couldn't be an endless loop problem.
What is an fso problem?
 
FileSystemObject = FSO
you gain access to the servers file system with this object. basic functionality is to gain access to files and or create them but you can search file contents, search directories for files and a few hundred other ways of utilizing it. :p
_______________________________________________
[sub]{ str = &quot;sleep is good for you. sleep gives you the energy you need to function&quot;;
ptr = /sleep/gi;Nstr = str.replace(ptr,&quot;coffee&quot;);alert(Nstr); }[/sub]
_______________________________________________
for the best results to your questions: FAQ333-2924
has you're questio
 
So do you have any suggestion as to why it takes
so long to generate my report? I try to index
certain fields as well as compact my Access database,
but it still takes 10 minutes to generate the page.
The thing that it puzzles me is that it didn't
take this long before?
 
what is the db up to capacity wise? if it didn't before but you've inserted say 10,000 records over time then you may want to consider going to mySQL or efficient way to store the data.

it could really be anything. server is running poorly at this time to a bad piece of data in the DB causing it to what I call skip (that one will get Tarwn :p). without a full look at everything which you are the only one that can really do with multiple tests you'll not find the true cause.

have you changed anything recently at all?
_______________________________________________
[sub]{ str = &quot;sleep is good for you. sleep gives you the energy you need to function&quot;;
ptr = /sleep/gi;Nstr = str.replace(ptr,&quot;coffee&quot;);alert(Nstr); }[/sub]
_______________________________________________
for the best results to your questions: FAQ333-2924
has you're questio
 
I haven't change any codes. The only thing I've changed is that I've added more records into the database.
So far, my database contains about 17,000 records.
I don't think I have max out my capacity.
 
I can say from expierience that access gets slow after 10,000. I'm sure a few others can say the same.

look into mySQL it's free and there is hardly any difference in connecting.

connection string is very similar but a few minor changes

a member here snowboardr has some good tutorials and explanations also at his site _______________________________________________
[sub]{ str = &quot;sleep is good for you. sleep gives you the energy you need to function&quot;;
ptr = /sleep/gi;Nstr = str.replace(ptr,&quot;coffee&quot;);alert(Nstr); }[/sub]
_______________________________________________
for the best results to your questions: FAQ333-2924
has you're questio
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top