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
595
Appointments Sort takes a lot of time
posted

Hi Guys,

i'm using the UltraDayView to show a calendar with appointments on it.

The problem is when i have a lot of appointments on the calendar and I add another one - A sort is being made and it takes a long time (something like 40sec-60sec).

The sort is being made every time i'm touching Appointments.All property, Appointments.GetEnumerator etc.

All of this is resulting in a really bad performance.

Is there anything that can be done in order to turn off the sorting? Why do we need to sort those appointments? 

I'm using version 10.1

Thanks,

Ziv.

Parents
  • 23930
    Offline posted

    Hi Ziv,

    Thank you for posting in our forums.

    If the appointment collection has changed then when accessing it through the properties you have mentioned will indeed sort the collection. This is done, because the ordinal positions of the Appointment objects in the collection must coincide with their chronological order. Otherwise the control will behave unpredictably as it relies on this. What you can do if you have bad performance, because of the sort is to use the SuspendSort method. This method will stop the sorting until the ResumeSort method is called. This can help you when you are modifying the appointment collection a lot of times (like adding a large number of appointments). Then you can suspend the sort when you start adding them and then resume it after you are done with that operation. For more information on this method please visit this link:

    http://help.infragistics.com/Help/Doc/WinForms/2014.1/CLR4.0/html/Infragistics4.Win.UltraWinSchedule.v14.1~Infragistics.Win.UltraWinSchedule.AppointmentsCollection~SuspendSort.html

    Please let me know if you have any additional questions.

Reply Children