Bulk Repaints - big issue for us

When we do things like change the date or change the timescale interval these things always kick off repaints of the Scheduler control calling onRenderCell and all these things. Is there a way to do like 4 or 5 things that would cause the scheduler control to redraw itself and then have it repaint ...

For example ...

this.schedulerObj.suspendRedraw = true; // <= THIS !!
this.schedulerObj.selectedDate = '...';
this.schedulerObj.timeScale.Interval = '...';
this.schedulerObj.yadayada = '...';
this.schedulerObj.yadayada = '...';
this.schedulerObj.suspendRedraw = false; // <= THIS !!
this.schedulerObj.refresh(). // let us tell it were done changing things that cause the UI to be invalid


1 Reply

BS Balasubramanian Sattanathan Syncfusion Team December 31, 2021 12:26 PM UTC

Hi Michael,

Greetings from Syncfusion Support.

We suspect that your requirement is needed to prevent the scheduler refresh when changing the multiple scheduler properties at the same time. It can be achieved by making use of setProperties method as like below code snippet. By using, you can change the multiple Scheduler properties at the same time by using (,) comma separator.

Code snippet:

this.scheduleObj.setProperties({ selectedDate: new Date(), timeScale: { slotCount: 4 } }, false)


Sample:
https://stackblitz.com/edit/angular-scheduler-setproperties?file=app.component.ts

Kindly try the above solution and let us know if this resolves your repaint problem.

Regards,
Balasubramanian S


Loader.
Up arrow icon