Get Excel Sheet Names
Audience:
Low-code EngineersSkill Prerequisites:
Actions,Tokens
Reads the names of the sheets in an Excel file (.xlsx) and saves them in tokens, as comma-separated text and as a JSON array. The names are in the same order as the sheet tabs in the file.
The file must already be on the site, for example uploaded through a form or created by another action.
note
This action requires the Excel feature package (EXGEN) to be licensed.
Typical Use Cases
- Check that an uploaded file has the sheet you expect before reading it with Create List from Excel (.xlsx)
- Show users the sheets of a file, so they can pick the one to import
- Log or return the structure of a workbook in an API
Don't use it to
- Read the data in a sheet. Use Create List from Excel (.xlsx) instead.
- Read older
.xlsfiles or CSV files. Only.xlsxfiles can be read. - List the files inside a ZIP archive. Use Get archive file names instead.
Related Actions
| Action Name | Description |
|---|---|
| Create List from Excel (.xlsx) | Reads the rows of a sheet into a list. |
| Create Excel from List | Writes a list to an Excel file. |
| Get archive file names | Lists the files in an archive. |
Input Parameter Reference
| Parameter | Description | Supports Tokens | Default | Required |
|---|---|---|---|---|
| FilePath | The Excel file to read. It can be a file ID, a relative URL, an absolute URL of a file on the site, a LinkClick URL or a physical path. In a form, select the Single File Upload field the user uploaded the file into, or switch to an expression to pass any of the other values. | Yes | empty string | Yes |
Output Parameters Reference
| Parameter | Description | Supports Tokens | Default | Required |
|---|---|---|---|---|
| Output Token Name CSV | A token name for the sheet names as comma-separated text, for example SheetNames. [SheetNames] gets Customers,Orders,Notes. | No | empty string | No |
| Output Token Name JSON | A token name for the sheet names as a JSON array, for example SheetNamesJson. [SheetNamesJson] gets ["Customers","Orders","Notes"]. | No | empty string | No |
Considerations
- File not found. If the file can't be found, the action fails with
Excel file not found. - Other file types. If the file isn't a valid
.xlsxfile, for example an.xlsor a password-protected file, the action fails. - Commas in sheet names. The CSV output doesn't quote names, so a sheet name that contains a comma looks like two names. Use the JSON output if sheet names can contain commas.
- Hidden sheets are included.
Examples
tip
To understand how to use the below examples, please see Running Examples.
1. Get the sheets of an uploaded file
This action reads the file with the ID in the [FileId] token, for example from an API request or a workflow. The sheet names are saved in the SheetNames token as comma-separated text and in the SheetNamesJson token as a JSON array.
{
"Title": "Get Excel Sheet Names",
"ActionType": "GetSheetNamesFromExcelFile",
"Description": "Read the sheet names of the import file",
"Parameters": {
"FilePath": "[FileId]",
"OutputTokenNameCSV": "SheetNames",
"OutputTokenNameJSON": "SheetNamesJson"
}
}
Revised 09/26/2026