Articles in this section
Category / Section

How to improve performance when loading grid with records and columns in WPF DataGrid (SfDataGrid)?

1 min read

The loading performance of WPF DataGrid (SfDataGrid) can be improved in following ways to provide better performance when loading millions of records with 1000+ columns,

1. Set EnableDataVirtualization as true for improving loading and data operations performance, where DataGrid will get loaded and process the data immediately regardless of number of records.

UG reference link: https://help.syncfusion.com/wpf/sfdatagrid/data-virtualization

2. Set UseDrawing property for improving loading and scrolling performance, where SfDataGrid cells drawn instead of loading TextBlock. This option can be used when you are loading more number of cells in View. For examples, you can use this when view displays 40 rows and more than 30 columns.

UG reference link: https://help.syncfusion.com/wpf/sfdatagrid/performance#improving-loading-and-scrolling-performance-using-lightweighttemplate

For more details about performance, you can refer below documentation link,

UG reference link: https://help.syncfusion.com/wpf/sfdatagrid/performance

<Grid>        
    <syncfusion:SfDataGrid ItemsSource="{Binding OrderCollection}"
                            EnableDataVirtualization="True"
                            UseDrawing="Default" 
                            ColumnSizer="None" >
    </syncfusion:SfDataGrid>       
</Grid>

 

For your reference, we have attached the sample in below location which loaded with 1000 columns.

Load the grid with more number of records in WPF DataGrid

View sample in GitHub.

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please sign in to leave a comment
Access denied
Access denied