Import 2 Dimension String Array into Excel Worksheet
This REST API imports a two‑dimensional string array into an Excel worksheet.
The request is an HTTP request with multipart content (see RFC 2046 or RFC 1341). The first part of the multipart content contains the Import2DimensionStringArrayOption data and the second part contains the data file.
REST API
POST https://api.aspose.cloud/v3.0/cells/import
POST https://api.aspose.cloud/v3.0/cells/{name}/importdata
Security and Authentication
The Aspose.Cells Cloud APIs are secure and require JWT token-based authentication.
The important parameters are described in the following table:
Import2DimensionStringArrayOption
| Parameter Name | Type | Description |
|---|---|---|
| FirstRow | int | Zero‑based index of the row where the import starts. |
| FirstColumn | int | Zero‑based index of the column where the import starts. |
| Data | String[,] | Two‑dimensional array containing the string values to be imported. |
| DestinationWorksheet | string | Name of the worksheet that will receive the imported data. |
| IsInsert | string (true/false) | If true, the data is inserted and existing cells are shifted accordingly. |
| ImportDataType | string | Specifies the data type; for this operation use TwoDimensionStringArray. |
| Source | FileSource | Indicates the data file location when the BatchData parameter is null. |
Example Request Body
{
"Data": [
["1.0", "2.9"],
["2.0", "2.1"]
],
"DestinationWorksheet": "Sheet2",
"FirstRow": 1,
"FirstColumn": 1,
"ImportDataType": "TwoDimensionStringArray"
}
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. An SDK abstracts 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: