We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Quick change page with grid on it throws an exception - removeEventListener bug.

In my current application when user changes the page - all components are destroyed and new ones are build dynamically (pretty common Angular way of handling routing)

From time to time, when user repeatedly changes page with grid - it throws below exception.

Because previously we've manually triggered grid?.destroy() in onDestroy - it was also breaking the app.

Without manual destroy() (or with try/catch) - it is still logged in console as not handled exception.



So the problem narrows down to this underscored line - it is called from refreshFilterValue with '

beforeDataBound' parameter and seems that is not included in ngBoundedEvents when grid is still not completly initialized, but destroyed due to the dynamic component build.



Is it a known issue, or do you know any helpful workaround to get rid of this problem?

1 Reply

HS Hemanthkumar S Syncfusion Team April 11, 2023 03:31 PM UTC

Hi RolJan,

Query: Quick change page with grid on it throws an exception

We have prepared a sample and tried to reproduce your mentioned issue at our end but it was unsuccessful. Please refer to the below sample for more information.

Sample Link: https://stackblitz.com/edit/angular-mregia-yu1d1x?file=src%2Fapp%2Fapp.module.ts

If you are still facing the issue, please try to reproduce the issue in the above attached sample and If possible please share the issue reproducing grid sample and video demon, which help us to better understand your query.


Hemanth Kumar S

Live Chat Icon For mobile
Up arrow icon