WorksheetExtensions.Import(Worksheet, String[,], Int32, Int32, DataImportOptions) Method
Imports data from a two-dimensional array of strings.
You need a license for the DevExpress Office File API Subscription or DevExpress Universal Subscription to use this method in production code.
Namespace: DevExpress.Spreadsheet
Assembly: DevExpress.Docs.v24.2.dll
NuGet Package: DevExpress.Document.Processor
#Declaration
public static void Import(
this Worksheet sheet,
string[,
] twoDimensionalArray,
int firstRowIndex,
int firstColumnIndex,
DataImportOptions options
)
#Parameters
Name | Type | Description |
---|---|---|
sheet | Worksheet | A Worksheet that is the worksheet to which the data is imported. |
two |
String[,] | A two-dimensional array of strings that is the data source. |
first |
Int32 | An integer that is the row index of the start cell in which the imported data will be inserted. |
first |
Int32 | An integer that is the column index of the start cell in which the imported data will be inserted. |
options | Data |
A Data |
#Example
Dim arrayR1C1() As String = { "a", "b", "=R1C1&R1C2" }
worksheet.Import(arrayR1C1, 0, 0, False, New DataImportOptions() With {.ImportFormulas = True, .ReferenceStyle = ReferenceStyle.R1C1})
Dim arrayLocalized() As String = { "a", "=1,2+1" }
worksheet.Import(arrayLocalized, 1, 0, False, New DataImportOptions() With {.ImportFormulas = True, .FormulaCulture = New System.Globalization.CultureInfo("de-DE")})