Skip to main content
Roberty Studio
AIMicrosoft 365

Excel

Read and edit Microsoft Excel spreadsheets from the agent.

Excel

Lets the agent read, write and manage the worksheets, cell ranges and tables of Excel files stored on OneDrive. It requires a Microsoft 365 connection configured in the workspace.

info

The Excel files have to be on OneDrive or SharePoint. Identify one by its ID (from a OneDrive action) or by its path on OneDrive (e.g. /Documents/spreadsheet.xlsx).

The available operations​

When you add this tool, choose which operations the agent is allowed to perform.


List the worksheets​

Returns every worksheet of an Excel file.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive (e.g. /Documents/spreadsheet.xlsx)

*Give either the file ID or the file path — not both.


Add a worksheet​

Creates a new worksheet in an Excel file.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
NameNo—The new worksheet's name. Omitted, Excel assigns a default (Sheet4, for instance)

*Give either the file ID or the file path.


Delete a worksheet​

Removes a worksheet from an Excel file.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Worksheet IDYes—The ID or name of the worksheet to delete

*Give either the file ID or the file path.


Read a range​

Reads the values of a range of cells.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Worksheet IDYes—The worksheet's ID or name (e.g. Sheet1)
AddressYes—The cell range's address (e.g. A1:D10, A1, A:C). Use usedRange to read the whole area that has data

*Give either the file ID or the file path.


Update a range​

Replaces the values of a range of cells with the ones you give.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Worksheet IDYes—The worksheet's ID or name
AddressYes—The address of the range to update (e.g. A1:C3)
ValuesYes—A two-dimensional array of values (rows × columns). E.g. [["Name", "Age"], ["João", 30]]

*Give either the file ID or the file path.


Clear a range​

Removes the values from a range of cells.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Worksheet IDYes—The worksheet's ID or name
AddressYes—The address of the range to clear (e.g. A1:D10)

*Give either the file ID or the file path.


List the tables​

Returns the formatted tables of one worksheet, or of the whole Excel file.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Worksheet IDNo—The worksheet's ID or name. Omitted, it lists the tables of the whole file

*Give either the file ID or the file path.


List a table's rows​

Returns the rows of a formatted table in an Excel file.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Table IDYes—The table's ID or name
Maximum resultsNo—How many rows to return at most
SkipNo—How many rows to skip (for paging)

*Give either the file ID or the file path.


Add rows to a table​

Inserts new rows into a formatted table.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Table IDYes—The table's ID or name
ValuesYes—The rows to add, as a two-dimensional array. E.g. [["João", 30, "SP"], ["Maria", 25, "RJ"]]
PositionNo—The insertion index (zero-based). Omitted, the rows go at the end

*Give either the file ID or the file path.


Delete a table row​

Removes one row from a formatted table.

ParameterRequiredDefaultWhat it is
File IDNo*—The Excel file's ID on OneDrive
File pathNo*—The file's path on OneDrive
Table IDYes—The table's ID or name
Row indexYes—The index of the row to delete (zero-based)

*Give either the file ID or the file path.