ImportArray(Double[],Int32,Int32,Boolean) Method
Imports an array of System.Double values into a worksheet.
Syntax
'Declaration Overloads Function ImportArray( _ ByVal arrDouble() As Double, _ ByVal firstRow As Integer, _ ByVal firstColumn As Integer, _ ByVal isVertical As Boolean _ ) As Integer
'Usage Dim instance As IWorksheet Dim arrDouble() As Double Dim firstRow As Integer Dim firstColumn As Integer Dim isVertical As Boolean Dim value As Integer value = instance.ImportArray(arrDouble, firstRow, firstColumn, isVertical)
int ImportArray( double[] arrDouble, int firstRow, int firstColumn, bool isVertical )
Parameters
- arrDouble
- Array of double value.
- firstRow
- Row of the first cell where array should be imported.
- firstColumn
- Column of the first cell where array should be imported.
- isVertical
- True if array should be imported vertically; False - horizontally.
Return Value
Number of imported elements.
Remarks
To know more about ImportArray refer this link
Example
The following code illustrates how to Imports an array of System.Double values into a worksheet with the specified row and column.
using Syncfusion.XlsIO; class Example { static void Main() { ExcelEngine excelEngine = new ExcelEngine(); IApplication application = excelEngine.Excel; application.DefaultVersion = ExcelVersion.Excel2013; IWorkbook workbook = application.Workbooks.Create(1); IWorksheet worksheet = workbook.Worksheets[0]; //Initialize the double Array double[] arrayDouble = new double[4] { 344.0045, 345.0045, 346.0045, 347.0045 }; //Import the double Array to Sheet worksheet.ImportArray(arrayDouble, 1, 1, true); workbook.SaveAs("ImportArray.xlsx"); workbook.Close(); excelEngine.Dispose(); } }
AssemblyVersion
Syncfusion.XlsIO.Base: 16.4460.0.52
See Also