IE: Script is causing Internet Explorer to run slowly & ajax


M

mthomsit

Hi,

I have a script which after a time shows the following error in IE:
"A script on this page is causing Internet Explorer to run slowly. If
it continues to run, your computer may become unresponsive".

The page is quite complex and uses ajax to post updates to the server,
updating parts of the page based on the response. It uses YUI (event
and dom mainly). There are no infinite loops or similar constructs.

The article here:
http://support.microsoft.com/kb/175500
suggests that it has exceeded the threshold of 5,000,000 operations.

Does anyone know if anything ever resets that threshold without the
user having refreshed the entire page?

Thanks
Mark
 
Ad

Advertisements

D

Doug Gunnoe

Hi,

I have a script which after a time shows the following error in IE:
"A script on this page is causing Internet Explorer to run slowly. If
it continues to run, your computer may become unresponsive".

The page is quite complex and uses ajax to post updates to the server,
updating parts of the page based on the response. It uses YUI (event
and dom mainly). There are no infinite loops or similar constructs.

The article here:http://support.microsoft.com/kb/175500
suggests that it has exceeded the threshold of 5,000,000 operations.

Does anyone know if anything ever resets that threshold without the
user having refreshed the entire page?

Thanks
Mark

Hi Mark,

I have had a similar problem like this in the past. In my case, the
script was hogging the browsers resources to where hardly anything
else could get done. My solution to the problem was to interrupt the
function from time to time with the setTimeout method. I think
something like setTimeout("yourBusyFunction()",0);

And passing it 0 is fine.
 
P

Peter Michaux

Hi,

I have a script which after a time shows the following error in IE:
"A script on this page is causing Internet Explorer to run slowly. If
it continues to run, your computer may become unresponsive".

The page is quite complex

What is making it so complex? Do you make a complex calculation? The
Ajax part of your app should not be making it run slowly.

Peter
 
M

mthomsit

What is making it so complex? Do you make a complex calculation? The
Ajax part of your app should not be making it run slowly.

Peter

Hi Peter,

Thanks for your help

I don't think the application is running slowly just that it exceeds
IE's threshold of 5000000 script operations for the page (I could be
wrong however).

This part of the app allows users to view a personal task list. They
must complete each task by linking it to documentary evidence. The
source of the documentary evidence is either a file upload (ajax
upload and ajax refresh of a list of documents they have already
uploaded), a search against documentum (ajax search returning result
set) or a working area which is a subset of documents from both.

Users select a number of tasks and documents to link to each other
which are shown in a preview. They then link them from the preview
and the tasklist updates (again via ajax). There are other time
saving features of the page (filters to tasks and documents, unlinking
documents, unlinking from all documents etc).

The users could spend quite a long period of time on the page,
uploading, searching, linking and unlinking and I think that is what's
pushing it above the threshold but I was hoping to understand if IE
ever reset the threshold or if anyone had suggestions of ways to
manage it.

Thanks
Mark
 
Ad

Advertisements

M

mthomsit

Hi Doug,

I think in this case it's not long loops that are causing the problem
but exceeding the scripts threshold in IE as the page is quite
complex. I am going to look through the scripts and just make sure
though

Cheers
Mark
 

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