Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
585
Binding / allocation to GanttView slow
posted

In my Gantt-View, data binding is taking ages.

Initial binding takes more than 30 seconds for a few thousand records, updating is slightly faster at around 8 seconds.

Even more puzzling, after update data has been merged (DataSet merge), I try to restore the last active task. When I allocate the task to the GanttView's ActiveTask property, again it takes longer than 30 seconds.

// re-select formerly selected task
if (_lastActiveTask != null)
{
foundTask = FindTask(_calendarInfo.Tasks, _lastActiveTask);
if (foundTask != null)
ultraGanttView.ActiveTask = foundTask;  <--- this takes ages
}

When I remove this allocation, the system will hang at the next allocation to the gantt chart:

// re-set scrollbar position
if (_firstVisibleTask != null)
{
foundTask = FindTask(_calendarInfo.Tasks, _firstVisibleTask);
if (foundTask != null)
ultraGanttView.EnsureTaskInView(foundTask, true); <--- this takes ages, when code above is removed
}

To sum up, always the first allocation plus binding and updating is taking far too long. I assume I missed out on some weird setting and appreciate any help :)

Before doing all that stuff, of course I do this:

ultraGanttView.BeginUpdate();
ultraGanttView.SuspendLayout();

Parents Reply Children