onGanttScroll not working in Angular


Hi, I have attached this using gantt.attachEvent method inside ngAfterViewInit hook (after all the data is loaded ) but it doesn’t log any data when gantt is scrolled. Only 0 0 is logged when it gets initialized.

Am I adding it in the wrong place ?


You need to use onGanttScroll handler where Gantt is initialized, i.e. you need to add this event in ngOnInit() method.
Please check the angular demo with onGanttScroll event: