What is the SHEETS function in Excel? This function returns the number of sheets in a reference or, in other words, the number of sheets within a reference in MS Excel.
SHEETS Function in Excel
How to Use the SHEETS Function in Excel
1. Description and Syntax:
This function calculates and returns the number of sheets within a reference. It is supported from Excel 2013 onwards.
Syntax: SHEETS(reference)
In which: Reference: Is the reference to find the number of sheets, it's a mandatory parameter.
Note:
- The SHEETS function includes all worksheets, along with all types of sheet elements like macros, charts...
- If the Reference value is invalid -> the function returns an error value #REF!
- Avoid using the SHEETS function in object models as they already possess similar functionalities.
- If you omit the Reference parameter, the function returns the total number of sheets in the current workspace.
2. Specific Scenario Example:
Suppose you need to calculate the quantity of pages within a reference described in the table below:
In the cell where calculation is needed -> input the formula: =SHEETS(B3)
Press Enter -> the returned value result is:
Similarly, copy the formula for the remaining values in the rows below and get the result:
In case you omit the Reference parameter -> the function returns the total number of sheets within the current workspace.
Here I've just introduced and guided you through the SHEETS function in Excel, which calculates the number of sheets within a reference. Its syntax is SHEETS(reference), where Reference is the reference to count sheets for and is a required parameter.
Wishing you swift mastery and success with formulas related to this function.
