NativeExcel for .Net Developer's Reference

IRange.SetDataTableMethod

Copies the specified DataTable into this range.

[Visual Basic]
FunctionSetDataTable(_
ByValtableAsDataTable,_
ByValColHeadersAsBoolean_
)AsInteger
[C#]
intSetDataTable(
DataTabletable,
boolColHeaders
);
[C++]
intSetDataTable(
DataTable*table,
boolColHeaders
);
[JScript]
functionSetDataTable(
DataTabletable,
boolColHeaders
):int;

Parameters

table
Specifies the source DataTable.
ColHeaders
True to specify that a row with column headers will be created from the DataTable's column names.

Return Value

Returns the number of copied rows.

Example

See Also

IRange Interface | NativeExcel Namespace | GetDataTable Method