The Excel SHEETS function returns the total number of sheets in a given reference. When no arguments are supplied SHEETS returns the total number of sheets in the workbook.
Syntax:= SHEETS ([reference])
The SHEETS function syntax has the following arguments:
- Reference Optional. Reference is a reference for which you want to know the number of sheets it contains. If Reference is omitted, SHEETS returns the number of sheets in the workbook that contains the function.
Example: Let’s look at some Excel SHEETS function examples and explore how to use the SHEETS function as a worksheet function in Microsoft Excel:
Based on the Excel spreadsheet above, the following SHEETS examples would return:
- If the reference is omitted, SHEETS returns total sheet count in a workbook
- The SHEETS function includes hidden sheets in the count
- SHEETS will report sheet count in 3D references
- SHEET reports the index of a sheet, the SHEETS function reports the number of sheets in a reference