Quantcast
Channel: DevExpress Support Center (Examples)
Viewing all articles
Browse latest Browse all 7205

How to: Load data dynamically using AsyncCollection

$
0
0

This example demonstrates how to use GridControl with our AsyncCollection, which allows loading data on demand. The collection's constructor receives two parameters:

1. A callback that returns the total number of items

2. A callback that returns items from required positions.

For example:

[C#]
varItems=newAsyncCollection<Item>(async()=>{return 1000;},async(intskipCount,inttakeCount)=>{returnawaitService1.GetDataAsync(skipCount,takeCount);});

Viewing all articles
Browse latest Browse all 7205

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>