Class DataTableFormatProvider
Converts between ADO.NET DataTable instances and spreadsheet workbooks, enabling bidirectional data exchange for tabular data integration.
Inheritance
Inherited Members
Namespace: Telerik.Windows.Documents.Spreadsheet.FormatProviders
Assembly: Telerik.Windows.Documents.Spreadsheet.dll
Syntax
public class DataTableFormatProvider
Constructors
DataTableFormatProvider()
Initializes a new instance of the DataTableFormatProvider class with default import and export settings.
Declaration
public DataTableFormatProvider()
Properties
ExportSettings
Gets or sets the settings controlling how worksheet data is exported to DataTable.
Declaration
public DataTableFormatProviderExportSettings ExportSettings { get; set; }
Property Value
|
DataTableFormatProviderExportSettings
|
ImportSettings
Gets or sets the settings controlling how DataTable data is imported into worksheets.
Declaration
public DataTableFormatProviderImportSettings ImportSettings { get; set; }
Property Value
|
DataTableFormatProviderImportSettings
|
Methods
Export(Worksheet)
Exports the specified worksheet to a new DataTable, converting cell values and types according to export settings.
Declaration
public DataTable Export(Worksheet worksheet)
Parameters
|
Worksheet
worksheet
The worksheet for export. |
Returns
|
System.Data.DataTable
the converted DataTable |
Import(DataTable)
Imports the specified DataTable into a new workbook, creating a worksheet with the table data.
Declaration
public Workbook Import(DataTable table)
Parameters
|
System.Data.DataTable
table
The DataTable for import. |
Returns
|
Workbook
the converted new Workbook. |
Import(DataTable, Worksheet)
Imports the specified DataTable into an existing worksheet, appending data at the configured start position.
Declaration
public void Import(DataTable table, Worksheet worksheet)
Parameters
|
System.Data.DataTable
table
The DataTable for import. |
|
Worksheet
worksheet
The Worksheet where the data should be added. |