# SHEETS Function

> Count the worksheets of a workbook with the SHEETS formula function of TX Sheet Control: syntax, a reference as the argument and an example with its result.

- **Product:** TX Sheet Control
- **Section:** Documentation
- **Kind:** Function
- **Path:** TX Sheet Control > API Reference > Formula Functions > SHEETS Function
- **170 words**
- **Web URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/sheets/
- **LLMs URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/sheets/llms.txt
- **LLMs-Full URL:** https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/sheets/llms-full.txt

---

Return the number of worksheets. Without an argument, SHEETS returns the number of sheets in the workbook. A reference to a single sheet as `value_or_reference` returns 1.

### Syntax

```text
SHEETS(value_or_reference)
```

Category: Information. Minimum arguments: 0. Maximum arguments: 1.

Available for supported offline calculation.

### Examples

```text
=SHEETS()
```

The formula returns 1 in a workbook with one sheet.

Cell and range examples require appropriate input values in the referenced cells. Handle invalid arguments, formula errors and array and spill constraints.

### See Also

- [Formulas](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/formulas/llms-full.txt)
- [Custom Functions and Formula Data](https://docs.textcontrol.com/tx-sheet-control/spreadsheets/custom-functions/llms-full.txt)

---

## Nearby

- **Previous:** [SHEET Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/sheet/llms-full.txt)
- **Next:** [SIGN Function](https://docs.textcontrol.com/tx-sheet-control/reference/formula-functions/sign/llms-full.txt)
