[]
Imports data from a data source (up to 2D) to the range.
DataImportResult ImportData(IEnumerable items, DataImportOptions options = null)
Function ImportData(items As IEnumerable, Optional options As DataImportOptions = Nothing) As DataImportResult
Type | Name | Description |
---|---|---|
IEnumerable | items | The items to import. The element type can be:
|
DataImportOptions | options | The import options. |
Type | Description |
---|---|
DataImportResult |
If the item collection is a list of primitive types, the orientation is determined by the shape of range. If the row count of the range is greater than column count, we import the collection vertically. Otherwise, we import the collection horizontally.
Type | Condition |
---|---|
InvalidCastException | The data type of a column is inconsistent. Use ItemTypeProvider to fix it. |
ArgumentException | An item is of an unsupported type or |
NotSupportedException | It's typically thrown when AOT compatibility issues occur at runtime. |
Imports data from a data source (up to 2D) to the range.
DataImportResult ImportData<T>(IEnumerable<T> items, DataImportOptions options = null)
Function ImportData(Of T)(items As IEnumerable(Of T), Optional options As DataImportOptions = Nothing) As DataImportResult
Type | Name | Description |
---|---|---|
IEnumerable<T> | items | The items to import. The element type can be:
|
DataImportOptions | options | The import options. |
Type | Description |
---|---|
DataImportResult |
Name | Description |
---|---|
T |
If the item collection is a list of primitive types, the orientation is determined by the shape of range. If the row count of the range is greater than column count, we import the collection vertically. Otherwise, we import the collection horizontally.
Type | Condition |
---|---|
InvalidCastException | The data type of a column is inconsistent. Check whether the implementation of ItemTypeProvider is correct. |
ArgumentException | An item is of an unsupported type or |
NotSupportedException | It's typically thrown when AOT compatibility issues occur at runtime. |
Imports data from a table to the range.
DataImportResult ImportData(DataTable table, DataImportOptions options = null)
Function ImportData(table As DataTable, Optional options As DataImportOptions = Nothing) As DataImportResult
Type | Name | Description |
---|---|---|
DataTable | table | The table to import. The column type can be: |
DataImportOptions | options | The import options. |
Type | Description |
---|---|
DataImportResult |
Type | Condition |
---|---|
InvalidCastException | The data type of a column is inconsistent. |
ArgumentException |
|
NotSupportedException | It's typically thrown when AOT compatibility issues occur at runtime. |