combit List & Label 29 - .NET Help
Programming Introduction / Examples / General / Database Independent Contents / Custom Data Structures / Contents
In This Topic
    Custom Data Structures / Contents
    In This Topic

    For data content apparently not directly supported, a suitable provider is found in most cases anyway. Business data from applications can generally be passed through the ObjectDataProvider class, if the data is present in comma-separated form, the data provider from the "Dataprovider” sample can be used. Many other data sources support the serialization to XML, so that the XmlDataProvider can be used.

    Your own class that implements the IDataProvider Interface can be used, too, of course. A good starting point is the "DataProvider" sample which demonstrates a simple CSV data provider (CsvDataProvider). Often one of the existing classes can be used as base class. If for example a data source is to be connected that implements the IDbConnection interface, it can be inherited from DbConnectionDataProvider . Only the Init Method has to be overwritten, where the available tables and relations have to be provided. The component help for .NET provides an example of how this is done for SQL Server data with the SqlConnectionDataProvider. Most database systems provide similar mechanisms.