Posted 18 September 2024, 5:00 am EST
Hi,
Whenever I am changing the itemsource data in flexgrid table. Table taking time to render and it gets unresponsive upto 10 seconds. After debugging my code I have figured it below code is creating problem.
onGridLoaded() {
if ( this.flexGrid.itemsSource ) {
this.addAlertIconColumn();
setTimeout( () => {
this.flexGrid.autoSizeColumns();
this.flexGrid.autoSizeRows();
if ( this.flexGrid && this.flexGrid[ ‘collectionView’ ] && this.flexGrid[ ‘collectionView’ ][ ‘currentItem’ ] ) {
this.flexGrid[ ‘collectionView’ ][ ‘currentItem’ ] = null;
this.flexGrid[ ‘collectionView’ ].collectionChanged.addHandler(() => this.assignColumns(false));
}
} );
}
}
calling above function on after grid loads. and other one is [autoRowHeights]=“true” also causing slowness.
Please suggest me any alternate way to auto size column and row.
Using “@grapecity/wijmo.angular2.all”: “5.20203.766” version.
Let me know if further details are required.