Import 2‑Dimension Double Array into Excel Worksheet

This REST API imports a two‑dimensional double array into an Excel worksheet.

The request is an HTTP POST with multipart content (see RFC 2046 or RFC 1341). The first part of the multipart body contains the Import2DimensionDoubleArrayOption data, and the second part contains the source data file.

REST API

POST https://api.aspose.cloud/v3.0/cells/import
POST https://api.aspose.cloud/v3.0/cells/{name}/importdata

The important parameters are described in the following table:

Import2DimensionDoubleArrayOption

Parameter Name Type Description
FirstRow int Row index (1‑based) where the import starts.
FirstColumn int Column index (1‑based) where the import starts.
Data Double[,] Two‑dimensional array of double values to be imported.
DestinationWorksheet string Name of the worksheet that will receive the data.
IsInsert string "true" to insert rows, "false" to overwrite existing cells.
ImportDataType string Type of data being imported (e.g., IntArray, DoubleArray, TwoDimensionDoubleArray, BatchData, csvData, etc.).
Source FileSource Indicates the data file location when the BatchData parameter is null.

Example

{
  "Data": [
    [1.0, 2.9, 3.1],
    [2.0, 2.1, 3.1]
  ],
  "DestinationWorksheet": "Sheet2",
  "FirstRow": 4,
  "FirstColumn": 1,
  "importDataType": "TwoDimensionDoubleArray"
}

Response

{
  "Status":"OK",
  "Code":200
}

Http Status Codes

Code Meaning Description
200 OK Compression succeeded; response contains compressed file details.
400 Bad Request Missing or invalid parameters (e.g., unsupported file type).
401 Unauthorized Invalid or missing JWT token.
413 Payload Too Large Uploaded file exceeds size limit.
500 Internal Server Error Unexpected server error.

How to Use the PostImportData API with SDKs

PostImportData API Specification

The OpenAPI Specification defines a publicly accessible programming interface that allows you to perform REST interactions directly from a web browser.

Use Aspose.Cells Cloud SDKs

Using an SDK is the fastest way to integrate this functionality. SDKs handle low‑level details so you can focus on your business logic. See the GitHub repository for a complete list of Aspose.Cells Cloud SDKs.

The following code examples demonstrate how to call Aspose.Cells web services using various SDKs: