DataProviderCollection

This data provider can be used to combine multiple other data providers into one data source. Use it if you have e.g. multiple DataSet classes from where to pull data or if you would like to have a mix of XML and custom object data. Example:

This provider supports the same sortings that the providers in the collection do support.

DataSet ds1 = CreateDataSet();

DataSet ds2 = CreateOtherDataSet();

 

// combine the data from ds1 and ds2 into one datasource 

DataProviderCollection providerCollection = new DataProviderCollection();

providerCollection.Add(new AdoDataProvider(ds1));

providerCollection.Add(new AdoDataProvider(ds2));

ListLabel LL = new ListLabel();

LL.DataSource = providerCollection;

LL.Design();

LL.Dispose();