ComponentOne Studio Web API Edition
Add/Delete Columns

Excel Web API service allows the user to add, update or delete columns from an excel sheet. Your client application sends an HTTP request to the Web API service application. This request uses GET and POST methods to seek a response from the service. While, GET method retrieves the intended information from the resource specified, POST method submits the data to the resource.

Excel Path, Sheet Name, and Column Indexes are common parameters for all the three operations specified below.

Add Column

To add a column in an excel sheet, you need to use a POST method.

POST: http://<host>[port]/api/excel/{excel path}/{sheet name}/columns/{column index}

The following illustration depicts a request URL with parameters to Add/Delete Column in an Excel file.


The following table elaborates request URL parameters required to Add/Delete Column in an Excel file.

Parameter

Values Supported

Description

ExcelPath

xls, xlsx

The excel file name that storage manager can recognize.

Sheet Name

String

The sheet name.

Column Index

Integer

The column index.

Update Columns

Allows the user to update the columns in an excel sheet, you can also use this REST API to hide/unhide or group/ungroup columns. To update a column in an excel sheet, you need to use the PUT method.

PUT: http://<host>[port]/api/excel/{excel path}/{sheet name}/columns/{column indexes}

Note: You can also update the column properties using the same Excel API service by specifying the column property name and value. Available properties are Visible(Boolean) and OutlineLevel(int).

Delete Columns

Allows the user to delete a column in an excel sheet. To delete a column in an excel sheet, you need to use the DELETE method.

DELETE: http://<host>[port]/api/excel/{excel path}/{sheet name}/columns/{column indexes}

 

 


Copyright © GrapeCity, inc. All rights reserved.

Product Support Forum |  Documentation Feedback