Reputation: 1
I have developed a devexpress grid in my application.
In that grid the data are around 10000 and all records are binding on page load event .
But I am facing an issue regarding performance. It will take more time to bind the 10000 records so I need to bind only 10 (page size) records on 1st page on page load.
Is there any way that bind only pagesize records on page load and bind another when page index has changed?
Please help me with this
Upvotes: 0
Views: 1166
Reputation: 18290
I suggest you use the Server-Mode data binding. If a grid contains a lot of records, it is recommended to bind it using Database Server Mode. This mode is specially designed to work with large data and provide much better performance in this case.
To switch grid pages using the scrollbar, use the grid's Virtual Scrolling feature. Please refer to the Grid - Data Paging and Scrolling. Virtual Scrolling online demo to see this approach in action.
References:
ASPxGridView with large data
ASPxGridView - How to bind the grid to a large dataset
How to load a large DataSet to ASPxGridView without using a datasource
ASPxGridView - How to bind a gridiview with a large data set to different data sources created at run time
ASPxGridView - How to improve performance for large data set
Upvotes: 1
Reputation: 431
I'm not sure why you need custom paging. However dev express has paging controls built into their framework you can use, have a look at this page here.
You will be able to use their code where it handles pages sizes which should help with your performance issues and far easier than building your own solution.
Upvotes: 0