List & Label 20 ships with more than twenty data providers that can be used to easily bind your reports to the data you require. Some of you might not even have noticed, because a lot of the magic happens under the hood. You can easily assign a SqlConnection instance to the DataSource property and will be presented with all parsable tables from this connection in the Designer. LL simply takes whatever you throw at it and tries to make sense of it. A DataSet, DataViewManager or a simple enumerable object are handled in the same way. The providers basically fall into four major groups:
ObjectDataProvider provider = new ObjectDataProvider(myBusinessObject, 2);
DataProviderCollection collection = new DataProviderCollection(); collection.Add(new XlsDataProvider(@"D:\datasources\Orders.xlsx", true); collection.Add(new SqlConnectionDataProvider(myConnection)); LL.DataSource = collection;
CsvDataProvider csv = newCsvDataProvider(@"D:\datasources\Customer.txt", true,"Customers",','); XlsDataProvider xls = new XlsDataProvider(@"D:\datasources\Orders.xlsx", true); InMemoryDataProvider inmem = new InMemoryDataProvider(); inmem.AddTable(csv, "Customers"); inmem.AddTable(xls, "Orders"); inmem.AddRelation("Customers", "Orders", "CustomerID", "CustomerID"); LL.DataSource = inmem;
Jochen Bartlau leads the development at combit as Managing Director. He's a Microsoft .NET enthusiast driving innovation & agile project management. The mobile devices geek who used to be a physicist in his first life loves to spend his spare time with his family.