search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

IE11, Win8.1 - extrem slow reactions

Asked by Daniel
5 years ago.

Hi,

i am using the Scheduler - newest Version. There are about 50 Resources having childs in 3 Levels.

Firefox: perfect.
IE11 -Compatibility View: fast, but event-text is cutted half off and timeheader-height is wrong (screenshot!)
IE11: extrem slow. Need about 5-10seconds to load/render the Scheduler cells. the CPU is going up to 30% when loading Events and the task-Manager says "inactive" for 3-4seconds

Thanks Dan!

greetz,
Daniel B

Comment posted by Dan Letecky [DayPilot]
5 years ago.

Daniel,

Is this page also slow in IE11?

http://javascript.daypilot.org/sandbox/scheduler/largedataset.html

I don't see any big problem there - it shows about 1500 events in 54 resource.

Comment posted by Daniel
5 years ago.

Hi,

your Page works fine.

Ok, the Problem could be my implementation of "loadEvents"... ?!

function loadEvents(beginn, ende)
{

if(!beginn)
{
beginn = dp.startDate;
}

if(!ende)
{
ende = new DayPilot.Date(dp.startDate).addDays(dp.days);
}

DayPilot.request("backend_events.php", function(result) {
var data = eval("(" + result.responseText + ")");

dp.events.list = data;
dp.update();

}, {start: beginn, end: ende}
);

}

Comment posted by Daniel
5 years ago.

I am calling this function here (every 15 sec):

dp.onAutoRefresh = function(args) {
console.log("refreshing, iteration #" + args.i);
loadEvents();
};

Comment posted by Dan Letecky [DayPilot]
5 years ago.

This method seems to be fine. However, calling it every 15 seconds can be hungry on resources.

Is it slow from the very beginning? Or does it get slower over time?

Comment posted by Daniel
5 years ago.

The Problem is the "dp.update();".... every time this function is fired, the cpu of the IE is going up to 20% for about 1-5seconds.

Start of the Scheduler -> 5-10seconds 20% CPU = "hanging" -> Scheduler Looks fine --> auto-reload/dp.update() --> 1-5seconds 20% CPU = "hanging" -> .......

PS:
I have to reload the Events from DB, because of a multi-user-usage.

Comment posted by Dan Letecky [DayPilot]
5 years ago.

How big is the response from "backend_events.php"?

You should filter the result set by the visible range to avoid loading unnecessary data - it takes longer time to receive the data from the server and it also takes a lot of time to parse the events on the client side.

Take a look at this tutorial, "Loading Events" section:

http://code.daypilot.org/87166/html5-scheduler

It uses .startDate and .days to limit the range - these properties are used to calculate "start" and "end" parameters that are sent to the backend_events.php script.

Answer posted by Daniel
5 years ago.

Loading less Events should be a good Thing. Now i am getting back about 20 Events. And the CPU is "only" going up to 6% when reloading. And when Scrolling at this Moment the Scheduler hangs for a short Moment.

Firefox is running without hanging a second :/ Damn IE....

The "dp.startDate" is NOT the date of the VISIBLE Start. It is the start of the whole Scheduler-calendar.

Answer posted by Daniel
5 years ago.

Output of this log: 31
Problem: with "live"-data there are about 100-150 Events! This could not be the Problem??

DayPilot.request("backend_events.php", function(result) {
var data = eval("(" + result.responseText + ")");

console.log(data.length);
dp.events.list = data;
dp.update();

}, {start: beginn, end: ende}
);

Comment posted by Dan Letecky [DayPilot]
5 years ago.

There should be no problem with loading 150 events. Just try the following page:

http://www.daypilot.org/demo/Scheduler/DynamicEventRendering.aspx

It's the ASP.NET version displaying 10,000 events. It's not super-fast but it's far from freezing, even in IE11.

There might be a different problem, specific to your page. I would suggest the following:

1. Try to profile the page in IE using Developer Tools (F12).
2. Check the onBefore*Render event handlers (such as onBeforeCellRender) to make sure they are not doing too much heavy-weight work. You can also try to disable them temporarily.

You can also try to optimize the page using other techniques (dynamic tree loading, dynamic event loading, etc.) but that wouldn't eliminate the problem. And if you have troubles loading 150 events there seems to be something wrong.

Answer posted by Daniel
5 years ago.

Got it! Thanks Dan!

I am calculating with js if there is a "public Holiday".

Doing it in "onBeforeTimeHeaderRender" and "onBeforeCellRender" is not a good idea with IE ;)

This question is more than 3 months old and has been closed. Please create a new question if you have anything to add.