Skip to content

Excel CRUD ​

Performs a wide range of read, write, and formatting operations on a local Excel workbook file.

Purpose ​

Use this task when a workflow needs to interact with an .xlsx file on disk — reading data from a worksheet, writing new rows, updating individual cells or ranges, applying formatting, managing worksheets, or running structural operations such as sort, filter, and pivot tables. The operation to perform is selected via the Mode field, which controls which additional fields are shown. All row and column indices are zero-based.

Inputs ​

FieldTypeRequiredDescription
ModeDropdownYesThe operation to perform. Determines which additional fields are shown.
Excel File PathTextYesAbsolute path to the .xlsx workbook file.
Worksheet NameTextYesThe name of the worksheet (tab) to operate on. Not required for CREATE_WORKBOOK. For DELETE_WORKSHEET, this is the name of the sheet to delete.
Start RowTextNoZero-based start row index (inclusive) for the read range.
End RowTextNoZero-based end row index (inclusive) for the read range. Leave blank to read to the last row.
Start ColumnTextNoZero-based start column index (inclusive) for the read range.
End ColumnTextNoZero-based end column index (inclusive) for the read range. Leave blank to read to the last column.
Cell ValuesMulti-line TextNoJSON array of values for the new row (CREATE mode) or values to set after insertion (INSERT mode).
At Row NumberTextNoZero-based row index to write the new row to. If blank, the row is appended to the first empty row.
Row NumberTextNoZero-based row index. In INSERT mode this is the position to insert before; in UPDATE and related modes it targets a specific cell row.
Column NumberTextNoZero-based column index of the target cell.
ValueTextNoNew value to write to a single cell.
Cell UpdatesKey-Value PairsNoMap of cell addresses (e.g. A1) to values for updating multiple cells at once.
Range AddressTextNoA1-style cell range (e.g. A1:C3) used by UPDATE_RANGE, FORMAT, MERGE, SORT, and FILTER modes.
ValuesMulti-line TextNo2D JSON array matching the size of the range, used to populate an UPDATE_RANGE operation.
Row NumbersMulti-line TextNoA single zero-based row index or a JSON array of indices specifying which rows to delete.
Column IdentifiersMulti-line TextNoJSON array of column letters or zero-based indices specifying which columns to delete or auto-fit.
FormulaTextNoExcel formula text to insert into the target cell (e.g. =SUM(A1:A10)).
Find TextTextNoText to search for in the worksheet.
Replace TextTextNoText to replace each match with.
Match CaseCheckboxNoWhen checked, the find-and-replace search is case-sensitive.
Match Whole CellCheckboxNoWhen checked, only cells whose entire content matches are replaced.
New Worksheet NameTextNoName of the new worksheet to add.
PositionTextNoOptional zero-based position at which to insert the new worksheet.
BoldCheckboxNoApply bold formatting to the range.
ItalicCheckboxNoApply italic formatting to the range.
UnderlineCheckboxNoApply underline formatting to the range.
Font NameTextNoFont family to apply (e.g. Arial).
Font SizeTextNoFont point size to apply.
Background ColorTextNoCell background fill colour as a hex code or named colour.
Font ColorTextNoFont colour as a hex code or named colour.
Number FormatTextNoNumber format mask to apply (e.g. 0.00, #,##0, dd-mmm-yyyy).
Wrap TextCheckboxNoEnable text wrapping in the formatted range.
Horizontal AlignmentDropdownNoHorizontal alignment to apply: General, Left, Center, or Right.
UnmergeCheckboxNoWhen checked, the range is unmerged instead of merged.
Sort ColumnTextNoZero-based index of the column within the range to sort by.
AscendingCheckboxNoSort order. Checked means ascending; unchecked means descending.
Filter CriteriaMulti-line TextNoJSON object mapping zero-based column indices to filter criteria strings (e.g. {"0": "=North", "2": ">100"}).
Source RangeTextNoA1-style range to copy or use as the pivot table data source.
Target WorksheetTextNoDestination worksheet name for COPY and PIVOT_TABLE modes.
Target CellTextNoTop-left destination cell for COPY and PIVOT_TABLE modes (e.g. A1).
First Row As HeaderCheckboxNoWhen checked, the first row of the sheet is treated as column headers during EXPORT_DATATABLE.
Initial Worksheet NameTextNoName to give the first worksheet when creating a new workbook.
Force Full CalculationCheckboxNoWhen checked, forces a complete workbook recalculation rather than a dependency-only pass.

Visibility Rules ​

Start Row is only shown when Mode is set to READ. End Row is only shown when Mode is set to READ. Start Column is only shown when Mode is set to READ. End Column is only shown when Mode is set to READ. Cell Values is only shown when Mode is set to CREATE or INSERT. At Row Number is only shown when Mode is set to CREATE. Row Number is only shown when Mode is set to INSERT, UPDATE, ADD_FORMULA, or GET_CELL. Column Number is only shown when Mode is set to UPDATE, ADD_FORMULA, or GET_CELL. Value is only shown when Mode is set to UPDATE. Cell Updates is only shown when Mode is set to UPDATE_CELLS. Range Address is only shown when Mode is set to UPDATE_RANGE, FORMAT, MERGE, SORT, or FILTER. Values is only shown when Mode is set to UPDATE_RANGE. Row Numbers is only shown when Mode is set to DELETE. Column Identifiers is only shown when Mode is set to DELETE_COLUMNS or AUTOFIT. Formula is only shown when Mode is set to ADD_FORMULA. Find Text is only shown when Mode is set to FIND_REPLACE. Replace Text is only shown when Mode is set to FIND_REPLACE. Match Case is only shown when Mode is set to FIND_REPLACE. Match Whole Cell is only shown when Mode is set to FIND_REPLACE. New Worksheet Name is only shown when Mode is set to ADD_WORKSHEET. Position is only shown when Mode is set to ADD_WORKSHEET. Bold is only shown when Mode is set to FORMAT. Italic is only shown when Mode is set to FORMAT. Underline is only shown when Mode is set to FORMAT. Font Name is only shown when Mode is set to FORMAT. Font Size is only shown when Mode is set to FORMAT. Background Color is only shown when Mode is set to FORMAT. Font Color is only shown when Mode is set to FORMAT. Number Format is only shown when Mode is set to FORMAT. Wrap Text is only shown when Mode is set to FORMAT. Horizontal Alignment is only shown when Mode is set to FORMAT. Unmerge is only shown when Mode is set to MERGE. Sort Column is only shown when Mode is set to SORT. Ascending is only shown when Mode is set to SORT. Filter Criteria is only shown when Mode is set to FILTER. Source Range is only shown when Mode is set to COPY or PIVOT_TABLE. Target Worksheet is only shown when Mode is set to COPY or PIVOT_TABLE. Target Cell is only shown when Mode is set to COPY or PIVOT_TABLE. First Row As Header is only shown when Mode is set to EXPORT_DATATABLE. Initial Worksheet Name is only shown when Mode is set to CREATE_WORKBOOK. Force Full Calculation is only shown when Mode is set to CALCULATE.

Operations ​

ModeWhat it does
READReads a range of rows and columns from the worksheet and returns the data.
CREATEWrites a new row of values to the worksheet, either appending or at a specific row index.
INSERTInserts a blank row at the specified index and optionally populates it with values.
UPDATESets a new value on a single cell identified by row and column index.
UPDATE_CELLSUpdates multiple cells at once using a cell-address-to-value map.
UPDATE_RANGEWrites a 2D array of values into an A1-style cell range.
DELETEDeletes one or more rows by their zero-based index.
DELETE_COLUMNSDeletes one or more columns by letter or zero-based index.
ADD_FORMULAInserts an Excel formula string into a specific cell.
GET_CELLRetrieves the value of a single cell by row and column index.
FIND_REPLACEFinds and replaces text across the entire worksheet with optional case and whole-cell matching.
ADD_WORKSHEETAdds a new worksheet to the workbook at an optional position.
DELETE_WORKSHEETDeletes the worksheet named in the Worksheet Name field.
FORMATApplies font, colour, alignment, and number formatting to a cell range.
MERGEMerges a cell range, or unmerges it when the Unmerge option is checked.
AUTOFITAuto-fits the width of specified columns.
SORTSorts the data within a range by a specified column, ascending or descending.
FILTERApplies auto-filter criteria to a range based on column-index-to-criteria mappings.
COPYCopies a cell range to a target cell on a destination worksheet.
PIVOT_TABLECreates a pivot table from a source range, placed at a target cell on a destination worksheet.
EXPORT_DATATABLEExports the worksheet data as a structured table object for use in downstream tasks.
CREATE_WORKBOOKCreates a new Excel workbook file with a single named worksheet.
CALCULATETriggers formula recalculation across the entire workbook.

Outputs ​

The outputs vary by mode. The result data is returned as named values from the operation service.

NameDescription
RowsThe rows of data read from the worksheet (READ and EXPORT_DATATABLE modes).
Cell ValueThe value of the retrieved cell (GET_CELL mode).
Workbook PathThe file path of the workbook that was created or modified.
MessageA description of the result (e.g. number of rows affected).

Tentech